[PATCH] D53765: [RFC prototype] Implementation of asm-goto support in LLVM

Bill Wendling via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 14 13:10:57 PST 2019


void added inline comments.


================
Comment at: lib/CodeGen/AsmPrinter/AsmPrinter.cpp:3006-3007
+  if (AGI != Pred->end()) {
+    // FIXME: this is crude, but the asm-goto sometimes seems to be the second-
+    // to-last instruction. Find a prettier way to check this.
+    const auto &AG = *AGI;
----------------
craig.topper wrote:
> void wrote:
> > This comment and the FIXME above it have me confused. Isn't the point of `callbr` to convert *all* asm goto statements into `callbr`? If so, then they should automatically be at the end of the basic block. What are the situations where it won't follow this?
> This is MachineIR not IR. INLINEASM has its own MachineInstr opcode which is not a terminator. Currently asm-goto is still using that.
*smacks forehead* Of course. Nevermind.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D53765/new/

https://reviews.llvm.org/D53765





More information about the llvm-commits mailing list