[LLVMbugs] [Bug 8949] New: Redefining a weak symbol crashes with integrated as
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Mon Jan 10 07:50:39 PST 2011
http://llvm.org/bugs/show_bug.cgi?id=8949
Summary: Redefining a weak symbol crashes with integrated as
Product: libraries
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: Target Description Classes
AssignedTo: unassignedbugs at nondot.org
ReportedBy: joerg at NetBSD.org
CC: llvmbugs at cs.uiuc.edu
Consider:
asm("bar:\n.weak foo\nfoo = bar");
int foo(void)
{
return 0;
}
Assembling first and pushing the result through the integrated assembler works
and correctly flags the redefinition. Compiling this directly with the
integrated assembler crashes with:
#2 0x00007ffff6cada71 in __assert_fail (
assertion=0x170c300 "!Symbol->isVariable() && \"Cannot emit a variable
symbol!\"", file=<value optimized out>, line=100,
function=0x1714780 "virtual void
llvm::MCObjectStreamer::EmitLabel(llvm::MCSymbol*)") at assert.c:81
#3 0x00000000010b0d89 in llvm::MCObjectStreamer::EmitLabel (
this=<value optimized out>, Symbol=0x1d629f0)
at
/home/joerg/work/infrastructure/llvm.org/llvm/lib/MC/MCObjectStreamer.cpp:100
#4 0x00000000010a0bcc in (anonymous namespace)::MCELFStreamer::EmitLabel (
this=0x1d5fd60, Symbol=0x3fc)
at
/home/joerg/work/infrastructure/llvm.org/llvm/lib/MC/MCELFStreamer.cpp:191
#5 0x0000000000da248e in llvm::AsmPrinter::EmitFunctionEntryLabel (
this=0x1d631f0)
at
/home/joerg/work/infrastructure/llvm.org/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp:468
#6 0x0000000000da5333 in llvm::AsmPrinter::EmitFunctionHeader (
this=0x1d631f0)
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list