[llvm] 08d9e2c - [NFC] Avoid useless BitVector move
via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 8 06:16:35 PST 2021
Author: serge-sans-paille
Date: 2021-03-08T15:16:23+01:00
New Revision: 08d9e2ceec60f4801b19243c6a4fcacb33aa043c
URL: https://github.com/llvm/llvm-project/commit/08d9e2ceec60f4801b19243c6a4fcacb33aa043c
DIFF: https://github.com/llvm/llvm-project/commit/08d9e2ceec60f4801b19243c6a4fcacb33aa043c.diff
LOG: [NFC] Avoid useless BitVector move
Added:
Modified:
llvm/lib/CodeGen/CFIInstrInserter.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/CFIInstrInserter.cpp b/llvm/lib/CodeGen/CFIInstrInserter.cpp
index 23c7fea01f28..31346c935633 100644
--- a/llvm/lib/CodeGen/CFIInstrInserter.cpp
+++ b/llvm/lib/CodeGen/CFIInstrInserter.cpp
@@ -157,7 +157,7 @@ void CFIInstrInserter::calculateCFAInfo(MachineFunction &MF) {
// Initialize MBBMap.
for (MachineBasicBlock &MBB : MF) {
- MBBCFAInfo MBBInfo;
+ MBBCFAInfo &MBBInfo = MBBVector[MBB.getNumber()];
MBBInfo.MBB = &MBB;
MBBInfo.IncomingCFAOffset = InitialOffset;
MBBInfo.OutgoingCFAOffset = InitialOffset;
@@ -165,7 +165,6 @@ void CFIInstrInserter::calculateCFAInfo(MachineFunction &MF) {
MBBInfo.OutgoingCFARegister = InitialRegister;
MBBInfo.IncomingCSRSaved.resize(NumRegs);
MBBInfo.OutgoingCSRSaved.resize(NumRegs);
- MBBVector[MBB.getNumber()] = MBBInfo;
}
CSRLocMap.clear();
More information about the llvm-commits
mailing list