[LLVMbugs] [Bug 8407] New: llvm-gcc generates bad assembly: invalid sections for operation on ...

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Oct 18 07:20:22 PDT 2010


http://llvm.org/bugs/show_bug.cgi?id=8407

           Summary: llvm-gcc generates bad assembly: invalid sections for
                    operation on ...
           Product: tools
           Version: 2.8
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: llvm-gcc
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: markus at oberhumer.com
                CC: llvmbugs at cs.uiuc.edu


Created an attachment (id=5629)
 --> (http://llvm.org/bugs/attachment.cgi?id=5629)
Small C source code to demonstrate the problem.

llvm-gcc seems to generate bad assembly for jump-table offsets.

This could be related to bug2023.


Snippet from the attached source file:

#define LABEL_DIFF(t,a,b) ((t) ((const char*)&&a - (const char*)&&b))

int *test_short(int i)
{
    static const short t[] = { 0, LABEL_DIFF(short,l1,l0) };
    goto * (const void *) ((const char *)&&l0 + t[i]);
    l0: return &a;
    l1: return &b;
}

-- 
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