[PATCH] D90091: [SelectionDAGBuilder] Let asm constraint "i" accept an undef operand.

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 26 12:40:30 PDT 2020


nickdesaulniers requested changes to this revision.
nickdesaulniers added a comment.
This revision now requires changes to proceed.

Interesting, did this come from actual C code?  It looks to me like GCC and Clang both currently reject such input:

  int foo(void) {
      int x;
      asm volatile (""::"i"(x));
      return x;
  }

Why should we allow that? Seems more indicative of a bug in the source code?  Or do you have a different test case that more clearly illuminates the issue in LLVM?



================
Comment at: llvm/test/CodeGen/SystemZ/asm-20.ll:3
 
+; Test that asm goto can be compiled.
 define i32 @c() {
----------------
Probably don't need to reorder these?


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

https://reviews.llvm.org/D90091



More information about the llvm-commits mailing list