forked from OSchip/llvm-project
[DebugInfo][InstrRef] Short-circuit unnecessary preferred location map construction
Reviewed By: cota Differential Revision: https://reviews.llvm.org/D117162
This commit is contained in:
parent
fc7a9f36a9
commit
764e52f0d4
|
@ -283,6 +283,11 @@ public:
|
|||
LocIdx Idx = Location.Idx;
|
||||
ValueIDNum &VNum = MLocs[Idx.asU64()];
|
||||
VarLocs.push_back(VNum);
|
||||
|
||||
// Short-circuit unnecessary preferred location update.
|
||||
if (VLocs.empty())
|
||||
continue;
|
||||
|
||||
auto it = ValueToLoc.find(VNum);
|
||||
// In order of preference, pick:
|
||||
// * Callee saved registers,
|
||||
|
|
Loading…
Reference in New Issue