Patryk27 added inline comments.
================ Comment at: llvm/lib/Target/AVR/AVRISelLowering.cpp:2207 + MF->push_back(LoopBB); + MachineBasicBlock *ExitBB = EntryBB->splitAt(MI, false); + ---------------- Alright, this is wrong, after all - I've just tested it on a more elaborate code in rustc and `EntryBB->removeSuccessor(ExitBB);` triggers an LLVM panic (presumably because EntryBB == ExitBB). I kinda don't understand why doing something like this: ``` MachineBasicBlock *ExitBB = EntryBB->splitAt(MI, false); if (EntryBB == ExitBB) { assert(EntryBB->canFallThrough() && "Expected a fallthrough block!"); ExitBB = EntryBB->getFallThrough(); } ``` ... is not sufficient, though 👀 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153197/new/ https://reviews.llvm.org/D153197 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits