65 _adr_type = in(Address)->bottom_type()->isa_ptr(); |
65 _adr_type = in(Address)->bottom_type()->isa_ptr(); |
66 #endif |
66 #endif |
67 dump_adr_type(this, _adr_type, st); |
67 dump_adr_type(this, _adr_type, st); |
68 |
68 |
69 Compile* C = Compile::current(); |
69 Compile* C = Compile::current(); |
70 if( C->alias_type(_adr_type)->is_volatile() ) |
70 if (C->alias_type(_adr_type)->is_volatile()) { |
71 st->print(" Volatile!"); |
71 st->print(" Volatile!"); |
|
72 } |
|
73 if (_unaligned_access) { |
|
74 st->print(" unaligned"); |
|
75 } |
|
76 if (_mismatched_access) { |
|
77 st->print(" mismatched"); |
|
78 } |
72 } |
79 } |
73 |
80 |
74 void MemNode::dump_adr_type(const Node* mem, const TypePtr* adr_type, outputStream *st) { |
81 void MemNode::dump_adr_type(const Node* mem, const TypePtr* adr_type, outputStream *st) { |
75 st->print(" @"); |
82 st->print(" @"); |
76 if (adr_type == NULL) { |
83 if (adr_type == NULL) { |
1147 if (!addr_t->is_known_instance() && |
1154 if (!addr_t->is_known_instance() && |
1148 addr_t->is_ptr_to_boxed_value()) { |
1155 addr_t->is_ptr_to_boxed_value()) { |
1149 // Use _idx of address base (could be Phi node) for boxed values. |
1156 // Use _idx of address base (could be Phi node) for boxed values. |
1150 intptr_t ignore = 0; |
1157 intptr_t ignore = 0; |
1151 Node* base = AddPNode::Ideal_base_and_offset(in(Address), phase, ignore); |
1158 Node* base = AddPNode::Ideal_base_and_offset(in(Address), phase, ignore); |
|
1159 if (base == NULL) { |
|
1160 return this; |
|
1161 } |
1152 this_iid = base->_idx; |
1162 this_iid = base->_idx; |
1153 } |
1163 } |
1154 const Type* this_type = bottom_type(); |
1164 const Type* this_type = bottom_type(); |
1155 for (DUIterator_Fast imax, i = region->fast_outs(imax); i < imax; i++) { |
1165 for (DUIterator_Fast imax, i = region->fast_outs(imax); i < imax; i++) { |
1156 Node* phi = region->fast_out(i); |
1166 Node* phi = region->fast_out(i); |
3320 // an initialization. Returns zero if a check fails. |
3330 // an initialization. Returns zero if a check fails. |
3321 // On success, returns the (constant) offset to which the store applies, |
3331 // On success, returns the (constant) offset to which the store applies, |
3322 // within the initialized memory. |
3332 // within the initialized memory. |
3323 intptr_t InitializeNode::can_capture_store(StoreNode* st, PhaseTransform* phase, bool can_reshape) { |
3333 intptr_t InitializeNode::can_capture_store(StoreNode* st, PhaseTransform* phase, bool can_reshape) { |
3324 const int FAIL = 0; |
3334 const int FAIL = 0; |
|
3335 if (st->is_unaligned_access()) { |
|
3336 return FAIL; |
|
3337 } |
3325 if (st->req() != MemNode::ValueIn + 1) |
3338 if (st->req() != MemNode::ValueIn + 1) |
3326 return FAIL; // an inscrutable StoreNode (card mark?) |
3339 return FAIL; // an inscrutable StoreNode (card mark?) |
3327 Node* ctl = st->in(MemNode::Control); |
3340 Node* ctl = st->in(MemNode::Control); |
3328 if (!(ctl != NULL && ctl->is_Proj() && ctl->in(0) == this)) |
3341 if (!(ctl != NULL && ctl->is_Proj() && ctl->in(0) == this)) |
3329 return FAIL; // must be unconditional after the initialization |
3342 return FAIL; // must be unconditional after the initialization |
4023 // If anything remains to be zeroed, zero it all now. |
4036 // If anything remains to be zeroed, zero it all now. |
4024 zeroes_done = align_size_down(zeroes_done, BytesPerInt); |
4037 zeroes_done = align_size_down(zeroes_done, BytesPerInt); |
4025 // if it is the last unused 4 bytes of an instance, forget about it |
4038 // if it is the last unused 4 bytes of an instance, forget about it |
4026 intptr_t size_limit = phase->find_intptr_t_con(size_in_bytes, max_jint); |
4039 intptr_t size_limit = phase->find_intptr_t_con(size_in_bytes, max_jint); |
4027 if (zeroes_done + BytesPerLong >= size_limit) { |
4040 if (zeroes_done + BytesPerLong >= size_limit) { |
4028 assert(allocation() != NULL, ""); |
4041 AllocateNode* alloc = allocation(); |
4029 if (allocation()->Opcode() == Op_Allocate) { |
4042 assert(alloc != NULL, "must be present"); |
4030 Node* klass_node = allocation()->in(AllocateNode::KlassNode); |
4043 if (alloc != NULL && alloc->Opcode() == Op_Allocate) { |
|
4044 Node* klass_node = alloc->in(AllocateNode::KlassNode); |
4031 ciKlass* k = phase->type(klass_node)->is_klassptr()->klass(); |
4045 ciKlass* k = phase->type(klass_node)->is_klassptr()->klass(); |
4032 if (zeroes_done == k->layout_helper()) |
4046 if (zeroes_done == k->layout_helper()) |
4033 zeroes_done = size_limit; |
4047 zeroes_done = size_limit; |
4034 } |
4048 } |
4035 } |
4049 } |