1229 // Note that some Identity methods call phase->type(this). |
1229 // Note that some Identity methods call phase->type(this). |
1230 // Make sure that the type array is big enough for |
1230 // Make sure that the type array is big enough for |
1231 // our new node, even though we may throw the node away. |
1231 // our new node, even though we may throw the node away. |
1232 // (This tweaking with igvn only works because x is a new node.) |
1232 // (This tweaking with igvn only works because x is a new node.) |
1233 igvn->set_type(x, t); |
1233 igvn->set_type(x, t); |
|
1234 // If x is a TypeNode, capture any more-precise type permanently into Node |
|
1235 // othewise it will be not updated during igvn->transform since |
|
1236 // igvn->type(x) is set to x->Value() already. |
|
1237 x->raise_bottom_type(t); |
1234 Node *y = x->Identity(igvn); |
1238 Node *y = x->Identity(igvn); |
1235 if( y != x ) { |
1239 if( y != x ) { |
1236 wins++; |
1240 wins++; |
1237 x = y; |
1241 x = y; |
1238 } else { |
1242 } else { |
1407 // it is possible that p1 will have a type like Foo*[int+]:NotNull*+any. |
1411 // it is possible that p1 will have a type like Foo*[int+]:NotNull*+any. |
1408 // In fact, that could have been the original type of p1, and p1 could have |
1412 // In fact, that could have been the original type of p1, and p1 could have |
1409 // had an original form like p1:(AddP x x (LShiftL quux 3)), where the |
1413 // had an original form like p1:(AddP x x (LShiftL quux 3)), where the |
1410 // expression (LShiftL quux 3) independently optimized to the constant 8. |
1414 // expression (LShiftL quux 3) independently optimized to the constant 8. |
1411 if ((t->isa_int() == NULL) && (t->isa_long() == NULL) |
1415 if ((t->isa_int() == NULL) && (t->isa_long() == NULL) |
1412 && Opcode() != Op_LoadKlass) { |
1416 && Opcode() != Op_LoadKlass && Opcode() != Op_LoadNKlass) { |
1413 // t might actually be lower than _type, if _type is a unique |
1417 // t might actually be lower than _type, if _type is a unique |
1414 // concrete subclass of abstract class t. |
1418 // concrete subclass of abstract class t. |
1415 // Make sure the reference is not into the header, by comparing |
1419 // Make sure the reference is not into the header, by comparing |
1416 // the offset against the offset of the start of the array's data. |
1420 // the offset against the offset of the start of the array's data. |
1417 // Different array types begin at slightly different offsets (12 vs. 16). |
1421 // Different array types begin at slightly different offsets (12 vs. 16). |