< prev index next >

src/hotspot/share/gc/shared/c2/barrierSetC2.cpp

Print this page




 581     } else {
 582       // Include klass to copy by 8 bytes words.
 583       base_off = instanceOopDesc::klass_offset_in_bytes();
 584     }
 585     assert(base_off % BytesPerLong == 0, "expect 8 bytes alignment");
 586   }
 587   Node* src_base  = kit->basic_plus_adr(src,  base_off);
 588   Node* dst_base = kit->basic_plus_adr(dst, base_off);
 589 
 590   // Compute the length also, if needed:
 591   Node* countx = size;
 592   countx = kit->gvn().transform(new SubXNode(countx, kit->MakeConX(base_off)));
 593   countx = kit->gvn().transform(new URShiftXNode(countx, kit->intcon(LogBytesPerLong) ));
 594 
 595   const TypePtr* raw_adr_type = TypeRawPtr::BOTTOM;
 596 
 597   ArrayCopyNode* ac = ArrayCopyNode::make(kit, false, src_base, NULL, dst_base, NULL, countx, false, false);
 598   ac->set_clonebasic();
 599   Node* n = kit->gvn().transform(ac);
 600   if (n == ac) {

 601     kit->set_predefined_output_for_runtime_call(ac, ac->in(TypeFunc::Memory), raw_adr_type);
 602   } else {
 603     kit->set_all_memory(n);
 604   }
 605 }
 606 
 607 Node* BarrierSetC2::obj_allocate(PhaseMacroExpand* macro, Node* ctrl, Node* mem, Node* toobig_false, Node* size_in_bytes,
 608                                  Node*& i_o, Node*& needgc_ctrl,
 609                                  Node*& fast_oop_ctrl, Node*& fast_oop_rawmem,
 610                                  intx prefetch_lines) const {
 611 
 612   Node* eden_top_adr;
 613   Node* eden_end_adr;
 614 
 615   macro->set_eden_pointers(eden_top_adr, eden_end_adr);
 616 
 617   // Load Eden::end.  Loop invariant and hoisted.
 618   //
 619   // Note: We set the control input on "eden_end" and "old_eden_top" when using
 620   //       a TLAB to work around a bug where these values were being moved across




 581     } else {
 582       // Include klass to copy by 8 bytes words.
 583       base_off = instanceOopDesc::klass_offset_in_bytes();
 584     }
 585     assert(base_off % BytesPerLong == 0, "expect 8 bytes alignment");
 586   }
 587   Node* src_base  = kit->basic_plus_adr(src,  base_off);
 588   Node* dst_base = kit->basic_plus_adr(dst, base_off);
 589 
 590   // Compute the length also, if needed:
 591   Node* countx = size;
 592   countx = kit->gvn().transform(new SubXNode(countx, kit->MakeConX(base_off)));
 593   countx = kit->gvn().transform(new URShiftXNode(countx, kit->intcon(LogBytesPerLong) ));
 594 
 595   const TypePtr* raw_adr_type = TypeRawPtr::BOTTOM;
 596 
 597   ArrayCopyNode* ac = ArrayCopyNode::make(kit, false, src_base, NULL, dst_base, NULL, countx, false, false);
 598   ac->set_clonebasic();
 599   Node* n = kit->gvn().transform(ac);
 600   if (n == ac) {
 601     ac->_adr_type = TypeRawPtr::BOTTOM;
 602     kit->set_predefined_output_for_runtime_call(ac, ac->in(TypeFunc::Memory), raw_adr_type);
 603   } else {
 604     kit->set_all_memory(n);
 605   }
 606 }
 607 
 608 Node* BarrierSetC2::obj_allocate(PhaseMacroExpand* macro, Node* ctrl, Node* mem, Node* toobig_false, Node* size_in_bytes,
 609                                  Node*& i_o, Node*& needgc_ctrl,
 610                                  Node*& fast_oop_ctrl, Node*& fast_oop_rawmem,
 611                                  intx prefetch_lines) const {
 612 
 613   Node* eden_top_adr;
 614   Node* eden_end_adr;
 615 
 616   macro->set_eden_pointers(eden_top_adr, eden_end_adr);
 617 
 618   // Load Eden::end.  Loop invariant and hoisted.
 619   //
 620   // Note: We set the control input on "eden_end" and "old_eden_top" when using
 621   //       a TLAB to work around a bug where these values were being moved across


< prev index next >