[PATCH] D115410: [llvm][test] rewrite callbr to use i rather than X constraint NFC

Nick Desaulniers via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 8 16:57:35 PST 2021


nickdesaulniers created this revision.
Herald added subscribers: wenlei, pengfei, asbirlea, zzheng, kbarton, hiraditya, nemanjai.
nickdesaulniers requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.

In D115311 <https://reviews.llvm.org/D115311>, we're looking to modify clang to emit i constraints rather
than X constraints for callbr's indirect destinations. Prior to doing
so, update all of the existing tests in llvm/ to match.

[clang][CGStmt] emit i constraint rather than X for asm goto indirect dests

As suggested in:
https://reviews.llvm.org/D114895#3177794
this will help simplify SelectionDAGISEL.

[SelectionDAGBuilder] drop special handling for CallBr

Now that indirect destinations are using "i" constraints rather than "X"
we no longer need this special handling.

Add a test case that was previously ICE'ing.

Reported-by: kernel test robot <lkp at intel.com>
Fixes: https://github.com/ClangBuiltLinux/linux/issues/1512


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D115410

Files:
  clang/lib/CodeGen/CGStmt.cpp
  clang/test/CodeGen/asm-goto.c
  clang/test/CodeGen/asm.c
  clang/test/Modules/asm-goto.c
  llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
  llvm/test/Assembler/call-arg-is-callee.ll
  llvm/test/Bitcode/callbr.ll
  llvm/test/Bitcode/callbr.ll.bc
  llvm/test/CodeGen/AArch64/callbr-asm-label.ll
  llvm/test/CodeGen/AArch64/callbr-asm-obj-file.ll
  llvm/test/CodeGen/AArch64/speculation-hardening-sls.ll
  llvm/test/CodeGen/ARM/speculation-hardening-sls.ll
  llvm/test/CodeGen/PowerPC/ppc64-inlineasm-clobber.ll
  llvm/test/CodeGen/SystemZ/asm-20.ll
  llvm/test/CodeGen/X86/callbr-asm-bb-exports.ll
  llvm/test/CodeGen/X86/callbr-asm-blockplacement.ll
  llvm/test/CodeGen/X86/callbr-asm-branch-folding.ll
  llvm/test/CodeGen/X86/callbr-asm-destinations.ll
  llvm/test/CodeGen/X86/callbr-asm-errors.ll
  llvm/test/CodeGen/X86/callbr-asm-instr-scheduling.ll
  llvm/test/CodeGen/X86/callbr-asm-kill.mir
  llvm/test/CodeGen/X86/callbr-asm-label-addr.ll
  llvm/test/CodeGen/X86/callbr-asm-obj-file.ll
  llvm/test/CodeGen/X86/callbr-asm-outputs-pred-succ.ll
  llvm/test/CodeGen/X86/callbr-asm-outputs.ll
  llvm/test/CodeGen/X86/callbr-asm-phi-placement.ll
  llvm/test/CodeGen/X86/callbr-asm-sink.ll
  llvm/test/CodeGen/X86/callbr-asm.ll
  llvm/test/CodeGen/X86/callbr-codegenprepare.ll
  llvm/test/CodeGen/X86/shrinkwrap-callbr.ll
  llvm/test/CodeGen/X86/tail-dup-asm-goto.ll
  llvm/test/Instrumentation/MemorySanitizer/msan_asm_conservative.ll
  llvm/test/Transforms/CallSiteSplitting/callsite-split-callbr.ll
  llvm/test/Transforms/Coroutines/coro-debug.ll
  llvm/test/Transforms/GVN/callbr-loadpre-critedge.ll
  llvm/test/Transforms/GVN/callbr-scalarpre-critedge.ll
  llvm/test/Transforms/GVN/critical-edge-split-failure.ll
  llvm/test/Transforms/IROutliner/illegal-callbr.ll
  llvm/test/Transforms/Inline/blockaddress.ll
  llvm/test/Transforms/Inline/callbr.ll
  llvm/test/Transforms/JumpThreading/callbr-edge-split.ll
  llvm/test/Transforms/JumpThreading/pr46857-callbr.ll
  llvm/test/Transforms/LICM/callbr-crash.ll
  llvm/test/Transforms/LoopDeletion/two-predecessors.ll
  llvm/test/Transforms/LoopRotate/callbr.ll
  llvm/test/Transforms/LoopStrengthReduce/callbr-critical-edge-splitting.ll
  llvm/test/Transforms/LoopStrengthReduce/callbr-critical-edge-splitting2.ll
  llvm/test/Transforms/LoopUnroll/callbr.ll
  llvm/test/Transforms/LoopUnswitch/callbr.ll
  llvm/test/Transforms/PGOProfile/callbr.ll
  llvm/test/Transforms/SimpleLoopUnswitch/not-safe-to-clone.ll
  llvm/test/Transforms/SimplifyCFG/callbr-destinations.ll
  llvm/test/Verifier/callbr.ll
  llvm/test/tools/llvm-diff/callbr.ll
  llvm/test/tools/llvm-diff/phinode.ll
  llvm/test/tools/llvm-reduce/remove-function-arguments-of-funcs-used-in-blockaddress.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D115410.392982.patch
Type: text/x-patch
Size: 63828 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20211209/adb9aa7e/attachment-0001.bin>


More information about the cfe-commits mailing list