[llvm-commits] [llvm] r53370 - /llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
Anton Korobeynikov
asl at math.spbu.ru
Wed Jul 9 14:54:27 PDT 2008
Author: asl
Date: Wed Jul 9 16:54:26 2008
New Revision: 53370
URL: http://llvm.org/viewvc/llvm-project?rev=53370&view=rev
Log:
Remove a FIXME: we really need to use const_data section on darwin for
constant pool, if relocation model is not static. This directly maps to
the way how GCC works.
Modified:
llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
Modified: llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp?rev=53370&r1=53369&r2=53370&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp Wed Jul 9 16:54:26 2008
@@ -139,9 +139,10 @@
PrivateGlobalPrefix = "L"; // Marker for constant pool idxs
BSSSection = 0; // no BSS section.
ZeroFillDirective = "\t.zerofill\t"; // Uses .zerofill
- // FIXME: It seems, this should be .const_data if relocation model is not
- // static.
- ConstantPoolSection = "\t.const\n";
+ if (X86TM->getRelocationModel() != Reloc::Static)
+ ConstantPoolSection = "\t.const_data";
+ else
+ ConstantPoolSection = "\t.const\n";
JumpTableDataSection = "\t.const\n";
CStringSection = "\t.cstring";
CStringSection_ = getUnnamedSection("\t.cstring",
More information about the llvm-commits
mailing list