[LLVMbugs] [Bug 2024] New: Problem with ELF section attribute

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Wed Feb 13 12:32:24 PST 2008


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

           Summary: Problem with ELF section attribute
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: new bugs
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: hehaifeng2nd at gmail.com
                CC: llvmbugs at cs.uiuc.edu


Hi,

I am having problem of using LLVM on a program which contains
customized code section.
In addition to ".text" section for keeping code, the program has
another code section, called ".init.text".
The functions in this section are defined as
  "int foo (int, int) __attribute__ ((section (".init.text")));"

If I compile the program with gcc, this section(".init.text") will
have attributes of "AX" (means allocate space and
executable). However, if I first compile the program into llvm IR,
then convert IR to native assembly code using
llc, this section will not have "AX" attribute. This causes the native
executable fails when it tries to call a function
in .init.text section. Any suggestion? (btw, my platform is Linux
running on x86 machine.)

Haifeng


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