mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-22 03:54:33 +02:00
6673473: (Escape Analysis) Add the instance's field information to PhiNode
Avoid an infinite generation of instance's field values Phi nodes. Reviewed-by: never
This commit is contained in:
parent
000ac830a0
commit
30dc0edfc8
6 changed files with 166 additions and 59 deletions
|
@ -32,7 +32,18 @@ Node *PhaseIdealLoop::split_thru_phi( Node *n, Node *region, int policy ) {
|
|||
int wins = 0;
|
||||
assert( !n->is_CFG(), "" );
|
||||
assert( region->is_Region(), "" );
|
||||
Node *phi = new (C, region->req()) PhiNode( region, n->bottom_type() );
|
||||
|
||||
const Type* type = n->bottom_type();
|
||||
const TypeOopPtr *t_oop = _igvn.type(n)->isa_oopptr();
|
||||
Node *phi;
|
||||
if( t_oop != NULL && t_oop->is_instance_field() ) {
|
||||
int iid = t_oop->instance_id();
|
||||
int index = C->get_alias_index(t_oop);
|
||||
int offset = t_oop->offset();
|
||||
phi = new (C,region->req()) PhiNode(region, type, NULL, iid, index, offset);
|
||||
} else {
|
||||
phi = new (C,region->req()) PhiNode(region, type);
|
||||
}
|
||||
uint old_unique = C->unique();
|
||||
for( uint i = 1; i < region->req(); i++ ) {
|
||||
Node *x;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue