File tree Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -23984,18 +23984,16 @@ static SDValue performSTORECombine(SDNode *N,
23984
23984
return SDValue();
23985
23985
23986
23986
// Heuristic: If there are other users of integer scalars extracted from
23987
- // this vector that won't fold into the store -- abandon folding. This may
23988
- // extend the vector lifetime and disrupt paired stores.
23989
- for (auto Use = Vector->use_begin(), End = Vector->use_end(); Use != End;
23990
- ++Use) {
23991
- if (Use->getResNo() != Vector.getResNo())
23987
+ // this vector that won't fold into the store -- abandon folding. Applying
23988
+ // this fold may extend the vector lifetime and disrupt paired stores.
23989
+ for (const auto &Use : Vector->uses()) {
23990
+ if (Use.getResNo() != Vector.getResNo())
23992
23991
continue;
23993
- SDNode *User = Use->getUser();
23994
- if (User->getOpcode() == ISD::EXTRACT_VECTOR_ELT) {
23995
- if (!User->hasOneUse() ||
23996
- (*User->user_begin())->getOpcode() != ISD::STORE)
23997
- return SDValue();
23998
- }
23992
+ const SDNode *User = Use.getUser();
23993
+ if (User->getOpcode() == ISD::EXTRACT_VECTOR_ELT &&
23994
+ (!User->hasOneUse() ||
23995
+ (*User->user_begin())->getOpcode() != ISD::STORE))
23996
+ return SDValue();
23999
23997
}
24000
23998
24001
23999
EVT FPElemVT = EVT::getFloatingPointVT(ElemVT.getSizeInBits());
You can’t perform that action at this time.
0 commit comments