[PATCH] D42509: [LivePhysRegs] Preserve pristine registers in blocks with no successors.

Evgeny Astigeevich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 30 05:53:20 PST 2018


eastig added a comment.

Hi Eli,

The patch causes a compiler crash whilst compiling Spec2k 176.gcc/src/insn-attrtab.c on Linux Cortex-A9.
The clang command:

  clang  -DNDEBUG  -O3 -DNDEBUG -ffast-math -mcpu=cortex-a9 -mthumb -fomit-frame-pointer   ""   -w -Werror=date-time -std=gnu89 -DSPEC_CPU2000 -D__DATE__=\"XXX\" -D__TIME__=\"XXX\" -c ./CINT2000/176.gcc/src/insn-attrtab.c

I am attaching a test created with bugpoint:
F5795184: test.ll <https://reviews.llvm.org/F5795184>

To reproduce:

  $ llc -O3 -o /dev/null -filetype=asm test.ll
  llc: ../lib/Target/ARM/Thumb2SizeReduction.cpp:965: bool UpdateCPSRUse(llvm::MachineInstr&, bool): Assertion `LiveCPSR && "CPSR liveness tracking is wrong!"' failed.
  #0 0x0000000001fbbfba llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/work/repos/llvm01/build.b/bin/llc+0x1fbbfba)
  #1 0x0000000001fba17e llvm::sys::RunSignalHandlers() (/work/repos/llvm01/build.b/bin/llc+0x1fba17e)
  #2 0x0000000001fba2e0 SignalHandler(int) (/work/repos/llvm01/build.b/bin/llc+0x1fba2e0)
  #3 0x00007fbbe63a5330 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x10330)
  #4 0x00007fbbe518dc37 gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x36c37)
  #5 0x00007fbbe5191028 abort (/lib/x86_64-linux-gnu/libc.so.6+0x3a028)
  #6 0x00007fbbe5186bf6 (/lib/x86_64-linux-gnu/libc.so.6+0x2fbf6)
  #7 0x00007fbbe5186ca2 (/lib/x86_64-linux-gnu/libc.so.6+0x2fca2)
  #8 0x0000000000ba2814 (anonymous namespace)::Thumb2SizeReduce::runOnMachineFunction(llvm::MachineFunction&) (/work/repos/llvm01/build.b/bin/llc+0xba2814)
  #9 0x0000000001747da5 llvm::MachineFunctionPass::runOnFunction(llvm::Function&) (/work/repos/llvm01/build.b/bin/llc+0x1747da5)
  #10 0x0000000001a5f3a3 llvm::FPPassManager::runOnFunction(llvm::Function&) (/work/repos/llvm01/build.b/bin/llc+0x1a5f3a3)
  #11 0x0000000001a5f44c llvm::FPPassManager::runOnModule(llvm::Module&) (/work/repos/llvm01/build.b/bin/llc+0x1a5f44c)
  #12 0x0000000001a5fcba llvm::legacy::PassManagerImpl::run(llvm::Module&) (/work/repos/llvm01/build.b/bin/llc+0x1a5fcba)
  #13 0x00000000007dc358 compileModule(char**, llvm::LLVMContext&) (/work/repos/llvm01/build.b/bin/llc+0x7dc358)
  #14 0x000000000076bd74 main (/work/repos/llvm01/build.b/bin/llc+0x76bd74)
  #15 0x00007fbbe5178f45 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x21f45)
  #16 0x00000000007d0726 _start (/work/repos/llvm01/build.b/bin/llc+0x7d0726)
  Stack dump:
  0.      Program arguments: /work/repos/llvm01/build.b/bin/llc -O3 -o /dev/null -filetype=asm test.ll
  1.      Running pass 'Function Pass Manager' on module 'test.ll'.
  2.      Running pass 'Thumb2 instruction size reduce pass' on function '@test'
  Aborted

Thanks,
Evgeny Astigeevich


Repository:
  rL LLVM

https://reviews.llvm.org/D42509





More information about the llvm-commits mailing list