[PATCH] D46671: Use iteration instead of recursion in CFIInserter
Violeta Vukobrat via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 11 07:01:24 PDT 2018
violetav added inline comments.
================
Comment at: lib/CodeGen/CFIInstrInserter.cpp:236
+ MBBCFAInfo &SuccInfo = MBBVector[Succ->getNumber()];
+ SuccInfo.IncomingCFAOffset = CurrentInfo.OutgoingCFAOffset;
+ SuccInfo.IncomingCFARegister = CurrentInfo.OutgoingCFARegister;
----------------
You could add
```
if (SuccInfo.Processed) continue;
```
above this to avoid setting incoming values and pushing the block onto the stack multiple times.
================
Comment at: lib/CodeGen/CFIInstrInserter.cpp:295
errs() << "*** Inconsistent CFA register and/or offset between pred and succ "
"***\n";
+ errs() << "Pred: " << Pred.MBB->getName() << " #" << Pred.MBB->getNumber()
----------------
Could you print out the function name as well? Seems it might be useful.
Repository:
rL LLVM
https://reviews.llvm.org/D46671
More information about the llvm-commits
mailing list