[LLVMbugs] [Bug 5851] New: llvm binds wrong symbols for stdcall functions

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Tue Dec 22 02:04:23 PST 2009


           Summary: llvm binds wrong symbols for stdcall functions
           Product: tools
           Version: 2.6
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Keywords: compile-fail
          Severity: major
          Priority: P2
         Component: llvm-as
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: ga55gees6m at sneakemail.com
                CC: llvmbugs at cs.uiuc.edu

struct A
        __stdcall void (*p)();

static __stdcall void MyFunc()

struct A B={MyFunc};
>llvm-gcc -pipe -c tmp.c -o tmp.o
>ld tmp.o -o tmp.exe
tmp.o:fake:(.data+0x0): undefined reference to `MyFunc'

It must be MyFunc at 0 to begin with... It definitely generates cdecl symbol for
stdcall function.
This prevents building COM vtables.
IR looks ok, so this an llvm-as bug, I'm unsure who is responsible for
generation of right symbols.

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