< prev index next >

src/share/vm/opto/lcm.cpp

Print this page




 179       break;
 180     case Op_StoreB:
 181     case Op_StoreC:
 182     case Op_StoreCM:
 183     case Op_StoreD:
 184     case Op_StoreF:
 185     case Op_StoreI:
 186     case Op_StoreL:
 187     case Op_StoreP:
 188     case Op_StoreN:
 189     case Op_StoreNKlass:
 190       was_store = true;         // Memory op is a store op
 191       // Stores will have their address in slot 2 (memory in slot 1).
 192       // If the value being nul-checked is in another slot, it means we
 193       // are storing the checked value, which does NOT check the value!
 194       if( mach->in(2) != val ) continue;
 195       break;                    // Found a memory op?
 196     case Op_StrComp:
 197     case Op_StrEquals:
 198     case Op_StrIndexOf:

 199     case Op_AryEq:


 200     case Op_EncodeISOArray:

 201       // Not a legit memory op for implicit null check regardless of
 202       // embedded loads
 203       continue;
 204     default:                    // Also check for embedded loads
 205       if( !mach->needs_anti_dependence_check() )
 206         continue;               // Not an memory op; skip it
 207       if( must_clone[iop] ) {
 208         // Do not move nodes which produce flags because
 209         // RA will try to clone it to place near branch and
 210         // it will cause recompilation, see clone_node().
 211         continue;
 212       }
 213       {
 214         // Check that value is used in memory address in
 215         // instructions with embedded load (CmpP val1,(val2+off)).
 216         Node* base;
 217         Node* index;
 218         const MachOper* oper = mach->memory_inputs(base, index);
 219         if (oper == NULL || oper == (MachOper*)-1) {
 220           continue;             // Not an memory op; skip it




 179       break;
 180     case Op_StoreB:
 181     case Op_StoreC:
 182     case Op_StoreCM:
 183     case Op_StoreD:
 184     case Op_StoreF:
 185     case Op_StoreI:
 186     case Op_StoreL:
 187     case Op_StoreP:
 188     case Op_StoreN:
 189     case Op_StoreNKlass:
 190       was_store = true;         // Memory op is a store op
 191       // Stores will have their address in slot 2 (memory in slot 1).
 192       // If the value being nul-checked is in another slot, it means we
 193       // are storing the checked value, which does NOT check the value!
 194       if( mach->in(2) != val ) continue;
 195       break;                    // Found a memory op?
 196     case Op_StrComp:
 197     case Op_StrEquals:
 198     case Op_StrIndexOf:
 199     case Op_StrIndexOfChar:
 200     case Op_AryEq:
 201     case Op_StrInflatedCopy:
 202     case Op_StrCompressedCopy:
 203     case Op_EncodeISOArray:
 204     case Op_HasNegatives:
 205       // Not a legit memory op for implicit null check regardless of
 206       // embedded loads
 207       continue;
 208     default:                    // Also check for embedded loads
 209       if( !mach->needs_anti_dependence_check() )
 210         continue;               // Not an memory op; skip it
 211       if( must_clone[iop] ) {
 212         // Do not move nodes which produce flags because
 213         // RA will try to clone it to place near branch and
 214         // it will cause recompilation, see clone_node().
 215         continue;
 216       }
 217       {
 218         // Check that value is used in memory address in
 219         // instructions with embedded load (CmpP val1,(val2+off)).
 220         Node* base;
 221         Node* index;
 222         const MachOper* oper = mach->memory_inputs(base, index);
 223         if (oper == NULL || oper == (MachOper*)-1) {
 224           continue;             // Not an memory op; skip it


< prev index next >