[LLVMbugs] [Bug 68] New: llvmgcc asserts when compiling functions renamed with asm's

bugzilla-daemon at zion.cs.uiuc.edu bugzilla-daemon at zion.cs.uiuc.edu
Wed Oct 29 11:15:26 PST 2003


http://llvm.cs.uiuc.edu/bugs/show_bug.cgi?id=68

           Summary: llvmgcc asserts when compiling functions renamed with
                    asm's
           Product: tools
           Version: 1.0
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: llvm-gcc
        AssignedTo: sabre at nondot.org
        ReportedBy: sabre at nondot.org


llvmgcc asserts on this testcase:
----
struct foo { int X; };
struct bar { int Y; };

extern int Func(struct foo*) __asm__("Func64");
extern int Func64(struct bar*);

extern __inline__ int Func(struct foo *F) {
  return 1;
}

extern __inline__ int Func64(struct bar* B) {
  return 0;
}
---

$ llvmgcc -S test.c
cc1: ../../gcc-3.4/gcc/llvm-representation.c:776: llvm_function_print: Assertion
`isPrototype &&"Cannot forward away from a function implementation!"' failed.
test.c:16: internal compiler error: Aborted
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://llvm.cs.uiuc.edu> for instructions.


It's hard to believe that this is valid code, but gcc accepts it...

-Chris



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.



More information about the llvm-bugs mailing list