diff options
author | Kazu Hirata <kazu@google.com> | 2022-08-20 21:18:28 -0700 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2022-08-20 21:18:28 -0700 |
commit | 258531b7ac0d43fce84a008235c597f920a6af7e (patch) | |
tree | b34b34e61aecb6e353b573596560a68e05d873f0 /llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | |
parent | 06b551c944ff1cb4a21ca39c9e5ee6f67fc282ee (diff) | |
download | llvm-258531b7ac0d43fce84a008235c597f920a6af7e.zip llvm-258531b7ac0d43fce84a008235c597f920a6af7e.tar.gz llvm-258531b7ac0d43fce84a008235c597f920a6af7e.tar.bz2 |
Remove redundant initialization of Optional (NFC)
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp index aa3e7a3..23fde21 100644 --- a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp +++ b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp @@ -553,7 +553,7 @@ public: // Examine the remaining variable locations: if we can find the same value // again, we can recover the location. - Optional<LocIdx> NewLoc = None; + Optional<LocIdx> NewLoc; for (auto Loc : MTracker->locations()) if (Loc.Value == OldValue) NewLoc = Loc.Idx; @@ -1145,7 +1145,7 @@ bool InstrRefBasedLDV::transferDebugInstrRef(MachineInstr &MI, // Default machine value number is <None> -- if no instruction defines // the corresponding value, it must have been optimized out. - Optional<ValueIDNum> NewID = None; + Optional<ValueIDNum> NewID; // Try to lookup the instruction number, and find the machine value number // that it defines. It could be an instruction, or a PHI. @@ -1278,7 +1278,7 @@ bool InstrRefBasedLDV::transferDebugInstrRef(MachineInstr &MI, // Pick a location for the machine value number, if such a location exists. // (This information could be stored in TransferTracker to make it faster). - Optional<LocIdx> FoundLoc = None; + Optional<LocIdx> FoundLoc; for (auto Location : MTracker->locations()) { LocIdx CurL = Location.Idx; ValueIDNum ID = MTracker->readMLoc(CurL); |