[LLVMbugs] [Bug 18925] New: [MC/Mach-O], Incorrect symbol stub is chosen by assembler

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Feb 21 02:58:15 PST 2014


            Bug ID: 18925
           Summary: [MC/Mach-O], Incorrect symbol stub is chosen by
           Product: new-bugs
           Version: trunk
          Hardware: PC
                OS: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: alexander.musman at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

The following looks like a bug in clang (llvm's MC component), it chooses
incorrect symbol stub for the call instruction in the small testcase below.

> llvm-mc c2.s --filetype=obj -o=casm.o && otool -tV casm.o
(__TEXT,__text) section
0000000000000000        callq   0x15 ## symbol stub for: __ZTIi
0000000000000005        nopw    %cs:_main(%rax,%rax)

> cat c2.s
        .file "c.cpp"
        .section        __TEXT, __text
       .align    4
        .globl _main
        call      L___cxa_allocate_exception.stub
        .align    4
        .section __IMPORT,__jump_table,symbol_stubs,self_modifying_code,5
        .indirect_symbol ___cxa_throw
        .byte   0xf4,0xf4,0xf4,0xf4,0xf4
        .indirect_symbol __ZTIi
        .long 0
        .section __IMPORT,__jump_table,symbol_stubs,self_modifying_code,5
        .indirect_symbol ___cxa_allocate_exception
        .byte   0xf4,0xf4,0xf4,0xf4,0xf4

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/20140221/f505c112/attachment.html>

More information about the llvm-bugs mailing list