[LLVMbugs] [Bug 9780] New: [Win32] constant may be emitted to .rdata

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Apr 22 00:44:13 PDT 2011


           Summary: [Win32] constant may be emitted to .rdata
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: X86
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: geek4civic at gmail.com
                CC: llvmbugs at cs.uiuc.edu

For Win32 targets, constant tends to be emitted to .data, not to .rdata.

const char a[] = "Hello.";

@a = constant [7 x i8] c"Hello.\00", align 1

* MSVC(x64)
CONST   SEGMENT         ;2 .rdata        00000007
a       DB      'Hello.', 00H

* mingw32-gcc 4.4
.globl _a
        .section .rdata,"dr"
        .ascii "Hello.\0"

* {i686|x86_64}-mingw32-{clang, llc}
        .globl  _a                      # @a
        .asciz   "Hello."

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