< prev index next >

src/hotspot/share/opto/output.cpp

Print this page
*** 222,16 ***
      _code_offsets(),
      _node_bundling_limit(0),
      _node_bundling_base(nullptr),
      _orig_pc_slot(0),
      _orig_pc_slot_offset_in_bytes(0),
      _buf_sizes(),
      _block(nullptr),
      _index(0) {
    C->set_output(this);
    if (C->stub_name() == nullptr) {
!     _orig_pc_slot = C->fixed_slots() - (sizeof(address) / VMRegImpl::stack_slot_size);
    }
  }
  
  PhaseOutput::~PhaseOutput() {
    C->set_output(nullptr);
--- 222,20 ---
      _code_offsets(),
      _node_bundling_limit(0),
      _node_bundling_base(nullptr),
      _orig_pc_slot(0),
      _orig_pc_slot_offset_in_bytes(0),
+     _gc_barrier_save_slots(0),
+     _gc_barrier_save_slots_offset_in_bytes(-1),
      _buf_sizes(),
      _block(nullptr),
      _index(0) {
    C->set_output(this);
    if (C->stub_name() == nullptr) {
!     int reserved_gc_slots = BarrierSet::barrier_set()->barrier_set_c2()->reserved_slots();
+     _gc_barrier_save_slots = C->fixed_slots() - (reserved_gc_slots + 1) * sizeof(address) / VMRegImpl::stack_slot_size;
+     _orig_pc_slot          = C->fixed_slots() -                      1  * sizeof(address) / VMRegImpl::stack_slot_size;
    }
  }
  
  PhaseOutput::~PhaseOutput() {
    C->set_output(nullptr);

*** 1294,10 ***
--- 1298,11 ---
    // if the nmethod has been deoptimized.  (See 4932387, 4894843.)
  
    // Compute the byte offset where we can store the deopt pc.
    if (C->fixed_slots() != 0) {
      _orig_pc_slot_offset_in_bytes = C->regalloc()->reg2offset(OptoReg::stack2reg(_orig_pc_slot));
+     _gc_barrier_save_slots_offset_in_bytes = C->regalloc()->reg2offset(OptoReg::stack2reg(_gc_barrier_save_slots));
    }
  
    // Compute prolog code size
    _frame_slots = OptoReg::reg2stack(C->matcher()->_old_SP) + C->regalloc()->_framesize;
    assert(_frame_slots >= 0 && _frame_slots < 1000000, "sanity check");
< prev index next >