[LLVMbugs] [Bug 22333] New: Crash when compiling weirdly ordered stacksave/restore pair

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Jan 26 09:07:54 PST 2015


http://llvm.org/bugs/show_bug.cgi?id=22333

            Bug ID: 22333
           Summary: Crash when compiling weirdly ordered stacksave/restore
                    pair
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: jaak.randmets at cyber.ee
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 13735
  --> http://llvm.org/bugs/attachment.cgi?id=13735&action=edit
File t.ll that crashes llc

I'm not quite sure if this code is even well-formed LLVM code. It was produced
by linking custom generated LLVM with some Clang generated LLVM code and
running "opt -O3" on it. Unfortunately I'm not able to post the full source
code but only the bugpoint simplified code (if needed I might be able to figure
something out).

Note that when the blocks foo and bar are swapped the crash does not happen. If
instead of the given intrinsics regular functions are called the crash also
does not happen.

The code is attached and "llc t.ll" will produce the following stack trace:
#0 0x1438ccc llvm::sys::PrintStackTrace(_IO_FILE*)
llvm.svn/lib/Support/Unix/Signals.inc:423:0
#1 0x1438f76 PrintStackTraceSignalHandler(void*)
llvm.svn/lib/Support/Unix/Signals.inc:481:0
#2 0x1437a69 SignalHandler(int) llvm.svn/lib/Support/Unix/Signals.inc:198:0
#3 0x7f0e7930aca0 (/lib64/libpthread.so.0+0xfca0)
#4 0x999c4a llvm::MachineInstr::getNumOperands() const
llvm.svn/include/llvm/CodeGen/MachineInstr.h:284:0
#5 0xda5829 llvm::MachineInstr::findRegisterUseOperandIdx(unsigned int, bool,
llvm::TargetRegisterInfo const*) const
llvm.svn/lib/CodeGen/MachineInstr.cpp:1140:0
#6 0x9f5d9a llvm::MachineInstr::readsRegister(unsigned int,
llvm::TargetRegisterInfo const*) const
llvm.svn/include/llvm/CodeGen/MachineInstr.h:842:0
#7 0xe8ac0c (anonymous
namespace)::RegisterCoalescer::joinReservedPhysReg(llvm::CoalescerPair&)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:1444:0
#8 0xe8f147 (anonymous
namespace)::RegisterCoalescer::joinIntervals(llvm::CoalescerPair&)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:2551:0
#9 0xe8a00a (anonymous
namespace)::RegisterCoalescer::joinCopy(llvm::MachineInstr*, bool&)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:1307:0
#10 0xe8f4b3 (anonymous
namespace)::RegisterCoalescer::copyCoalesceWorkList(llvm::MutableArrayRef<llvm::MachineInstr*>)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:2622:0
#11 0xe8f7a5 (anonymous
namespace)::RegisterCoalescer::copyCoalesceInMBB(llvm::MachineBasicBlock*)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:2663:0
#12 0xe8fbba (anonymous namespace)::RegisterCoalescer::joinAllIntervals()
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:2692:0
#13 0xe8ff65 (anonymous
namespace)::RegisterCoalescer::runOnMachineFunction(llvm::MachineFunction&)
llvm.svn/lib/CodeGen/RegisterCoalescer.cpp:2751:0
#14 0xd9f3b3 llvm::MachineFunctionPass::runOnFunction(llvm::Function&)
llvm.svn/lib/CodeGen/MachineFunctionPass.cpp:34:0
#15 0x10d0ea7 llvm::FPPassManager::runOnFunction(llvm::Function&)
llvm.svn/lib/IR/LegacyPassManager.cpp:1530:0
#16 0x10d1039 llvm::FPPassManager::runOnModule(llvm::Module&)
llvm.svn/lib/IR/LegacyPassManager.cpp:1550:0
#17 0x10d137b (anonymous namespace)::MPPassManager::runOnModule(llvm::Module&)
llvm.svn/lib/IR/LegacyPassManager.cpp:1608:0
#18 0x10d1a3a llvm::legacy::PassManagerImpl::run(llvm::Module&)
llvm.svn/lib/IR/LegacyPassManager.cpp:1715:0
#19 0x10d1c5b llvm::legacy::PassManager::run(llvm::Module&)
llvm.svn/lib/IR/LegacyPassManager.cpp:1749:0
#20 0x982c3e compileModule(char**, llvm::LLVMContext&)
llvm.svn/tools/llc/llc.cpp:350:0
#21 0x981d73 main llvm.svn/tools/llc/llc.cpp:199:0
#22 0x7f0e78539f60 __libc_start_main (/lib64/libc.so.6+0x1ff60)
#23 0x97ee59 _start (/home/jaak/usr/bin/llc+0x97ee59)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150126/72d66907/attachment.html>


More information about the llvm-bugs mailing list