< prev index next >

src/hotspot/share/gc/shenandoah/c2/shenandoahSupport.cpp

Print this page




2960                 if (mm == NULL) {
2961                   mm = allocate_merge_mem(mem, rep_proj, rep_ctrl);
2962                 }
2963                 nnew = mm;
2964               }
2965               _phase->igvn().replace_input_of(u, j, nnew);
2966               replaced = true;
2967             }
2968           }
2969           if (replaced) {
2970             --i;
2971           }
2972 
2973         }
2974       } else if ((u->adr_type() == TypePtr::BOTTOM && u->Opcode() != Op_StrInflatedCopy) ||
2975                  u->adr_type() == NULL) {
2976         assert(u->adr_type() != NULL ||
2977                u->Opcode() == Op_Rethrow ||
2978                u->Opcode() == Op_Return ||
2979                u->Opcode() == Op_SafePoint ||
2980                u->Opcode() == Op_StoreIConditional ||
2981                u->Opcode() == Op_StoreLConditional ||
2982                (u->is_CallStaticJava() && u->as_CallStaticJava()->uncommon_trap_request() != 0) ||
2983                (u->is_CallStaticJava() && u->as_CallStaticJava()->_entry_point == OptoRuntime::rethrow_stub()) ||
2984                u->Opcode() == Op_CallLeaf, "%s", u->Name());
2985         if (ShenandoahBarrierC2Support::is_dominator(rep_ctrl, _phase->ctrl_or_self(u), replacement, u, _phase)) {
2986           if (mm == NULL) {
2987             mm = allocate_merge_mem(mem, rep_proj, rep_ctrl);
2988           }
2989           _phase->igvn().replace_input_of(u, u->find_edge(mem), mm);
2990           --i;
2991         }
2992       } else if (_phase->C->get_alias_index(u->adr_type()) == _alias) {
2993         if (ShenandoahBarrierC2Support::is_dominator(rep_ctrl, _phase->ctrl_or_self(u), replacement, u, _phase)) {
2994           _phase->igvn().replace_input_of(u, u->find_edge(mem), rep_proj);
2995           --i;
2996         }
2997       }
2998     }
2999   }
3000 }
3001 
3002 ShenandoahLoadReferenceBarrierNode::ShenandoahLoadReferenceBarrierNode(Node* ctrl, Node* obj)
3003 : Node(ctrl, obj) {
3004   ShenandoahBarrierSetC2::bsc2()->state()->add_load_reference_barrier(this);


3184       case Op_GetAndSetB:
3185       case Op_GetAndSetS:
3186       case Op_GetAndSetP:
3187       case Op_GetAndSetN:
3188       case Op_GetAndAddL:
3189       case Op_GetAndAddI:
3190       case Op_GetAndAddB:
3191       case Op_GetAndAddS:
3192       case Op_ShenandoahEnqueueBarrier:
3193       case Op_FastLock:
3194       case Op_FastUnlock:
3195       case Op_Rethrow:
3196       case Op_Return:
3197       case Op_StoreB:
3198       case Op_StoreC:
3199       case Op_StoreD:
3200       case Op_StoreF:
3201       case Op_StoreL:
3202       case Op_StoreLConditional:
3203       case Op_StoreI:
3204       case Op_StoreIConditional:
3205       case Op_StoreVector:
3206       case Op_StrInflatedCopy:
3207       case Op_StrCompressedCopy:
3208       case Op_EncodeP:
3209       case Op_CastP2X:
3210       case Op_SafePoint:
3211       case Op_EncodeISOArray:
3212         strength = STRONG;
3213         break;
3214       case Op_LoadB:
3215       case Op_LoadUB:
3216       case Op_LoadUS:
3217       case Op_LoadD:
3218       case Op_LoadF:
3219       case Op_LoadL:
3220       case Op_LoadI:
3221       case Op_LoadS:
3222       case Op_LoadN:
3223       case Op_LoadP:
3224       case Op_LoadVector: {




2960                 if (mm == NULL) {
2961                   mm = allocate_merge_mem(mem, rep_proj, rep_ctrl);
2962                 }
2963                 nnew = mm;
2964               }
2965               _phase->igvn().replace_input_of(u, j, nnew);
2966               replaced = true;
2967             }
2968           }
2969           if (replaced) {
2970             --i;
2971           }
2972 
2973         }
2974       } else if ((u->adr_type() == TypePtr::BOTTOM && u->Opcode() != Op_StrInflatedCopy) ||
2975                  u->adr_type() == NULL) {
2976         assert(u->adr_type() != NULL ||
2977                u->Opcode() == Op_Rethrow ||
2978                u->Opcode() == Op_Return ||
2979                u->Opcode() == Op_SafePoint ||

2980                u->Opcode() == Op_StoreLConditional ||
2981                (u->is_CallStaticJava() && u->as_CallStaticJava()->uncommon_trap_request() != 0) ||
2982                (u->is_CallStaticJava() && u->as_CallStaticJava()->_entry_point == OptoRuntime::rethrow_stub()) ||
2983                u->Opcode() == Op_CallLeaf, "");
2984         if (ShenandoahBarrierC2Support::is_dominator(rep_ctrl, _phase->ctrl_or_self(u), replacement, u, _phase)) {
2985           if (mm == NULL) {
2986             mm = allocate_merge_mem(mem, rep_proj, rep_ctrl);
2987           }
2988           _phase->igvn().replace_input_of(u, u->find_edge(mem), mm);
2989           --i;
2990         }
2991       } else if (_phase->C->get_alias_index(u->adr_type()) == _alias) {
2992         if (ShenandoahBarrierC2Support::is_dominator(rep_ctrl, _phase->ctrl_or_self(u), replacement, u, _phase)) {
2993           _phase->igvn().replace_input_of(u, u->find_edge(mem), rep_proj);
2994           --i;
2995         }
2996       }
2997     }
2998   }
2999 }
3000 
3001 ShenandoahLoadReferenceBarrierNode::ShenandoahLoadReferenceBarrierNode(Node* ctrl, Node* obj)
3002 : Node(ctrl, obj) {
3003   ShenandoahBarrierSetC2::bsc2()->state()->add_load_reference_barrier(this);


3183       case Op_GetAndSetB:
3184       case Op_GetAndSetS:
3185       case Op_GetAndSetP:
3186       case Op_GetAndSetN:
3187       case Op_GetAndAddL:
3188       case Op_GetAndAddI:
3189       case Op_GetAndAddB:
3190       case Op_GetAndAddS:
3191       case Op_ShenandoahEnqueueBarrier:
3192       case Op_FastLock:
3193       case Op_FastUnlock:
3194       case Op_Rethrow:
3195       case Op_Return:
3196       case Op_StoreB:
3197       case Op_StoreC:
3198       case Op_StoreD:
3199       case Op_StoreF:
3200       case Op_StoreL:
3201       case Op_StoreLConditional:
3202       case Op_StoreI:

3203       case Op_StoreVector:
3204       case Op_StrInflatedCopy:
3205       case Op_StrCompressedCopy:
3206       case Op_EncodeP:
3207       case Op_CastP2X:
3208       case Op_SafePoint:
3209       case Op_EncodeISOArray:
3210         strength = STRONG;
3211         break;
3212       case Op_LoadB:
3213       case Op_LoadUB:
3214       case Op_LoadUS:
3215       case Op_LoadD:
3216       case Op_LoadF:
3217       case Op_LoadL:
3218       case Op_LoadI:
3219       case Op_LoadS:
3220       case Op_LoadN:
3221       case Op_LoadP:
3222       case Op_LoadVector: {


< prev index next >