[llvm-bugs] [Bug 32130] New: ARMConstantIslandPass.cpp:492: Assertion `Size >= 4 && "Too small constant pool entry"' failed

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Mar 3 09:28:56 PST 2017


https://bugs.llvm.org/show_bug.cgi?id=32130

            Bug ID: 32130
           Summary: ARMConstantIslandPass.cpp:492: Assertion `Size >= 4 &&
                    "Too small constant pool entry"' failed
           Product: libraries
           Version: 4.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: ARM
          Assignee: unassignedbugs at nondot.org
          Reporter: mail at timnn.me
                CC: llvm-bugs at lists.llvm.org

Created attachment 18047
  --> https://bugs.llvm.org/attachment.cgi?id=18047&action=edit
IR causing the assertion

Running `llc` with an optimization level >= 1 on the attached IR causes the
following assertion:

```
llc:
/home/logic/build-tmp/llvm-4.0/src/lib/Target/ARM/ARMConstantIslandPass.cpp:492:
void
{anonymous}::ARMConstantIslands::doInitialConstPlacement(std::vector<llvm::MachineInstr*>&):
Assertion `Size >= 4 && "Too small constant pool entry"' failed.
#0 0x0000559ecb6d40b8 llvm::sys::PrintStackTrace(llvm::raw_ostream&)
/home/logic/build-tmp/llvm-4.0/src/lib/Support/Unix/Signals.inc:406:0
#1 0x0000559ecb6d1ece llvm::sys::RunSignalHandlers()
/home/logic/build-tmp/llvm-4.0/src/lib/Support/Signals.cpp:45:0
#2 0x0000559ecb6d2034 SignalHandler(int)
/home/logic/build-tmp/llvm-4.0/src/lib/Support/Unix/Signals.inc:246:0
#3 0x00007f26fd021630 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x11630)
#4 0x00007f26fbd8f7ef gsignal
/build/glibc-jxM2Ev/glibc-2.24/signal/../sysdeps/unix/sysv/linux/raise.c:58:0
#5 0x00007f26fbd913ea abort /build/glibc-jxM2Ev/glibc-2.24/stdlib/abort.c:91:0
#6 0x00007f26fbd87bb7 __assert_fail_base
/build/glibc-jxM2Ev/glibc-2.24/assert/assert.c:92:0
#7 0x00007f26fbd87c62 (/lib/x86_64-linux-gnu/libc.so.6+0x2dc62)
#8 0x0000559eca66faa6
llvm::MachineBasicBlock::insert(llvm::MachineInstrBundleIterator<llvm::MachineInstr,
false>, llvm::MachineInstr*)
/home/logic/build-tmp/llvm-4.0/src/include/llvm/CodeGen/MachineBasicBlock.h:547:0
#9 0x0000559eca66faa6 llvm::BuildMI(llvm::MachineBasicBlock&,
llvm::MachineInstrBundleIterator<llvm::MachineInstr, false>, llvm::DebugLoc
const&, llvm::MCInstrDesc const&)
/home/logic/build-tmp/llvm-4.0/src/include/llvm/CodeGen/MachineInstrBuilder.h:334:0
#10 0x0000559eca66faa6 (anonymous
namespace)::ARMConstantIslands::doInitialConstPlacement(std::vector<llvm::MachineInstr*,
std::allocator<llvm::MachineInstr*> >&)
/home/logic/build-tmp/llvm-4.0/src/lib/Target/ARM/ARMConstantIslandPass.cpp:503:0
#11 0x0000559eca67495c (anonymous
namespace)::ARMConstantIslands::runOnMachineFunction(llvm::MachineFunction&)
/home/logic/build-tmp/llvm-4.0/src/lib/Target/ARM/ARMConstantIslandPass.cpp:364:0
#12 0x0000559ecb04c055
llvm::MachineFunctionPass::runOnFunction(llvm::Function&)
/home/logic/build-tmp/llvm-4.0/src/lib/CodeGen/MachineFunctionPass.cpp:62:0
#13 0x0000559ecb307b8b llvm::FPPassManager::runOnFunction(llvm::Function&)
/home/logic/build-tmp/llvm-4.0/src/lib/IR/LegacyPassManager.cpp:1513:0
#14 0x0000559ecb307c54 llvm::FPPassManager::runOnModule(llvm::Module&)
/home/logic/build-tmp/llvm-4.0/src/lib/IR/LegacyPassManager.cpp:1534:0
#15 0x0000559ecb308851 runOnModule
/home/logic/build-tmp/llvm-4.0/src/lib/IR/LegacyPassManager.cpp:1590:0
#16 0x0000559ecb308851 llvm::legacy::PassManagerImpl::run(llvm::Module&)
/home/logic/build-tmp/llvm-4.0/src/lib/IR/LegacyPassManager.cpp:1693:0
#17 0x0000559eca398258 compileModule(char**, llvm::LLVMContext&)
/home/logic/build-tmp/llvm-4.0/src/tools/llc/llc.cpp:530:0
#18 0x0000559eca334a20 main
/home/logic/build-tmp/llvm-4.0/src/tools/llc/llc.cpp:285:0
#19 0x00007f26fbd7a3f1 __libc_start_main
/build/glibc-jxM2Ev/glibc-2.24/csu/../csu/libc-start.c:325:0
#20 0x0000559eca38b73a _start (bin/llc+0x53b73a)
Stack dump:
0.      Program arguments: bin/llc bugpoint-reduced-simplified.ll
1.      Running pass 'Function Pass Manager' on module
'bugpoint-reduced-simplified.ll'.
2.      Running pass 'ARM constant island placement and branch shortening pass'
on function '@_ZN4farm4main17h8da056cb67c7e794E'
[1]    5497 abort      bin/llc bugpoint-reduced-simplified.ll
```

LLVM version is 4.0 RC3 build with `-DCMAKE_BUILD_TYPE=RelWithDebInfo
-DLLVM_ENABLE_ASSERTIONS=on`.

-- 
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/20170303/cf72a47a/attachment-0001.html>


More information about the llvm-bugs mailing list