File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -948,12 +948,13 @@ Constant *AMDGPUSwLowerLDS::getAddressesOfVariablesInKernel(
948948
949949 SmallVector<Constant *> Elements;
950950 for (auto *GV : Variables) {
951- if (!LDSParams.LDSToReplacementIndicesMap .contains (GV)) {
951+ auto It = LDSParams.LDSToReplacementIndicesMap .find (GV);
952+ if (It == LDSParams.LDSToReplacementIndicesMap .end ()) {
952953 Elements.push_back (
953954 PoisonValue::get (IRB.getPtrTy (AMDGPUAS::GLOBAL_ADDRESS)));
954955 continue ;
955956 }
956- auto &Indices = LDSParams. LDSToReplacementIndicesMap [GV] ;
957+ auto &Indices = It-> second ;
957958 Constant *GEPIdx[] = {ConstantInt::get (Int32Ty, Indices[0 ]),
958959 ConstantInt::get (Int32Ty, Indices[1 ]),
959960 ConstantInt::get (Int32Ty, Indices[2 ])};
You can’t perform that action at this time.
0 commit comments