[LoadCombine] Simplify code with a brace init. NFC.
llvm-svn: 277921
This commit is contained in:
parent
01d3a35aa3
commit
a3d4def878
|
@ -44,9 +44,6 @@ struct PointerOffsetPair {
|
|||
};
|
||||
|
||||
struct LoadPOPPair {
|
||||
LoadPOPPair() = default;
|
||||
LoadPOPPair(LoadInst *L, PointerOffsetPair P, unsigned O)
|
||||
: Load(L), POP(P), InsertOrder(O) {}
|
||||
LoadInst *Load;
|
||||
PointerOffsetPair POP;
|
||||
/// \brief The new load needs to be created before the first load in IR order.
|
||||
|
@ -264,7 +261,7 @@ bool LoadCombine::runOnBasicBlock(BasicBlock &BB) {
|
|||
auto POP = getPointerOffsetPair(*LI);
|
||||
if (!POP.Pointer)
|
||||
continue;
|
||||
LoadMap[POP.Pointer].push_back(LoadPOPPair(LI, POP, Index++));
|
||||
LoadMap[POP.Pointer].push_back({LI, std::move(POP), Index++});
|
||||
AST.add(LI);
|
||||
}
|
||||
if (combineLoads(LoadMap))
|
||||
|
|
Loading…
Reference in New Issue