Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix debug infos of nested variables #1134

Merged
merged 1 commit into from Sep 30, 2015

Conversation

kinke
Copy link
Member

@kinke kinke commented Sep 30, 2015

No description provided.

@kinke
Copy link
Member Author

kinke commented Sep 30, 2015

Sadly, it doesn't get rid of #930 at the same time. May really be an LLVM bug after all. ;)

dnadlinger added a commit that referenced this pull request Sep 30, 2015
Fix debug infos of nested variables
@dnadlinger dnadlinger merged commit 4116fdb into ldc-developers:master Sep 30, 2015
@dnadlinger
Copy link
Member

Whoops, was too quick in pressing the merge button, only the AppVeyor status was showing up. Let's hope I didn't break the Travis build.

@kinke
Copy link
Member Author

kinke commented Oct 1, 2015

Heh, no worries. :)
I've run dmd-testsuite-debug in both x64 and x86 on Linux (with LLVM 3.7), non-QUICK. There's only a single remaining issue, in 32-bit:

 ... runnable/mars1.d               (-inline -release -gc -O -fPIC)
Test failed.  The logged output:
/home/martin/build-ldc/bin/ldmd2 -conf= -m32 -Irunnable   -od/home/martin/build-ldc/dmd-testsuite-debug-32/runnable -of/home/martin/build-ldc/dmd-testsuite-debug-32/runnable/mars1_0 runnable/mars1.d
ldc2: /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:1130: llvm::SDValue llvm::SelectionDAG::getConstant(uint64_t, llvm::SDLoc, llvm::EVT, bool, bool): Assertion `(EltVT.getSizeInBits() >= 64 || (uint64_t)((int64_t)Val >> EltVT.getSizeInBits()) + 1 < 2) && "getConstant with a uint64_t value that doesn't fit in the type!"' failed.
#0 0x147b948 printSymbolizedStackTrace /home/martin/llvm/lib/Support/Unix/Signals.inc:346:0
#1 0x147b948 llvm::sys::PrintStackTrace(llvm::raw_ostream&) /home/martin/llvm/lib/Support/Unix/Signals.inc:438:0
#2 0x147aa89 SignalHandler(int) /home/martin/llvm/lib/Support/Unix/Signals.inc:210:0
#3 0x2af4d7b8c340 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x10340)
#4 0x2af4d8a0dcc9 gsignal /build/buildd/eglibc-2.19/signal/../nptl/sysdeps/unix/sysv/linux/raise.c:56:0
#5 0x2af4d8a110d8 abort /build/buildd/eglibc-2.19/stdlib/abort.c:91:0
#6 0x2af4d8a06b86 __assert_fail_base /build/buildd/eglibc-2.19/assert/assert.c:92:0
#7 0x2af4d8a06c32 (/lib/x86_64-linux-gnu/libc.so.6+0x2fc32)
#8 0xaadcf7 APInt /home/martin/llvm/include/llvm/ADT/APInt.h:238:0
#9 0xaadcf7 llvm::SelectionDAG::getConstant(unsigned long, llvm::SDLoc, llvm::EVT, bool, bool) /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:1131:0
#10 0x963996 llvm::X86TargetLowering::LowerReturn(llvm::SDValue, unsigned int, bool, llvm::SmallVectorImpl<llvm::ISD::OutputArg> const&, llvm::SmallVectorImpl<llvm::SDValue> const&, llvm::SDLoc, llvm::SelectionDAG&) const /home/martin/llvm/lib/Target/X86/X86ISelLowering.cpp:2013:0
#11 0xadeb4f llvm::SelectionDAGBuilder::visitRet(llvm::ReturnInst const&) /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:1274:0
#12 0xb01c2a llvm::Value::getValueID() const /home/martin/llvm/include/llvm/IR/Value.h:363:0
#13 0xb01c2a llvm::Instruction::getOpcode() const /home/martin/llvm/include/llvm/IR/Instruction.h:112:0
#14 0xb01c2a llvm::Instruction::isTerminator() const /home/martin/llvm/include/llvm/IR/Instruction.h:115:0
#15 0xb01c2a llvm::TerminatorInst::classof(llvm::Instruction const*) /home/martin/llvm/include/llvm/IR/InstrTypes.h:73:0
#16 0xb01c2a llvm::isa_impl<llvm::TerminatorInst, llvm::Instruction, void>::doit(llvm::Instruction const&) /home/martin/llvm/include/llvm/Support/Casting.h:56:0
#17 0xb01c2a llvm::isa_impl_cl<llvm::TerminatorInst, llvm::Instruction const*>::doit(llvm::Instruction const*) /home/martin/llvm/include/llvm/Support/Casting.h:96:0
#18 0xb01c2a llvm::isa_impl_wrap<llvm::TerminatorInst, llvm::Instruction const*, llvm::Instruction const*>::doit(llvm::Instruction const* const&) /home/martin/llvm/include/llvm/Support/Casting.h:122:0
#19 0xb01c2a llvm::isa_impl_wrap<llvm::TerminatorInst, llvm::Instruction const* const, llvm::Instruction const*>::doit(llvm::Instruction const* const&) /home/martin/llvm/include/llvm/Support/Casting.h:114:0
#20 0xb01c2a isa<llvm::TerminatorInst, const llvm::Instruction*> /home/martin/llvm/include/llvm/Support/Casting.h:134:0
#21 0xb01c2a llvm::SelectionDAGBuilder::visit(llvm::Instruction const&) /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:910:0
#22 0xb10ab1 llvm::SelectionDAGISel::SelectBasicBlock(llvm::ilist_iterator<llvm::Instruction const>, llvm::ilist_iterator<llvm::Instruction const>, bool&) /home/martin/llvm/include/llvm/ADT/ilist.h:60:0
#23 0xb1418e llvm::SelectionDAGISel::SelectAllBasicBlocks(llvm::Function const&) /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1317:0
#24 0xb16249 llvm::SelectionDAGISel::runOnMachineFunction(llvm::MachineFunction&) /home/martin/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:465:0
#25 0x922114 (anonymous namespace)::X86DAGToDAGISel::runOnMachineFunction(llvm::MachineFunction&) /home/martin/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp:175:0
#26 0x13cd680 llvm::FPPassManager::runOnFunction(llvm::Function&) /home/martin/llvm/lib/IR/LegacyPassManager.cpp:1520:0
#27 0x13cda1b llvm::FPPassManager::runOnModule(llvm::Module&) /home/martin/llvm/include/llvm/ADT/ilist.h:58:0
#28 0x13cdd14 runOnModule /home/martin/llvm/lib/IR/LegacyPassManager.cpp:1596:0
#29 0x13cdd14 llvm::legacy::PassManagerImpl::run(llvm::Module&) /home/martin/llvm/lib/IR/LegacyPassManager.cpp:1698:0
#30 0x620684 codegenModule(llvm::TargetMachine&, llvm::Module&, llvm::raw_fd_ostream&, llvm::TargetMachine::CodeGenFileType) /home/martin/ldc/driver/toobj.cpp:130:0
#31 0x620877 writeModule(llvm::Module*, std::string) /home/martin/ldc/driver/toobj.cpp:593:0
#32 0x61b2bb std::string::_M_data() const /usr/include/c++/4.8/bits/basic_string.h:293:0
#33 0x61b2bb std::string::_M_rep() const /usr/include/c++/4.8/bits/basic_string.h:301:0
#34 0x61b2bb ~basic_string /usr/include/c++/4.8/bits/basic_string.h:539:0
#35 0x61b2bb ldc::CodeGenerator::writeAndFreeLLModule(char const*) /home/martin/ldc/driver/codegenerator.cpp:171:0
#36 0x5ef398 main /home/martin/ldc/driver/main.cpp:1323:0
#37 0x2af4d89f8ec5 __libc_start_main /build/buildd/eglibc-2.19/csu/libc-start.c:321:0
#38 0x615bef _start (/home/martin/build-ldc/bin/ldc2+0x615bef)

@kinke
Copy link
Member Author

kinke commented Oct 1, 2015

Same picture with dmd-testsuite in release config: no failures on x64, the same ICE on x86.

@kinke kinke deleted the nestedDebuginfo branch October 5, 2015 21:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants