[llvm-commits] [llvm] r61484 - in /llvm/trunk: include/llvm/Target/TargetAsmInfo.h lib/CodeGen/AsmPrinter/DwarfWriter.cpp lib/Target/TargetAsmInfo.cpp lib/Target/X86/X86TargetAsmInfo.cpp
Bill Wendling
isanbard at gmail.com
Mon Dec 29 14:12:13 PST 2008
Author: void
Date: Mon Dec 29 16:12:11 2008
New Revision: 61484
URL: http://llvm.org/viewvc/llvm-project?rev=61484&view=rev
Log:
Linux wants the FDE initial location and address range to be forced to 32-bit.
Darwin doesn't. Make this optional for platforms.
Modified:
llvm/trunk/include/llvm/Target/TargetAsmInfo.h
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
llvm/trunk/lib/Target/TargetAsmInfo.cpp
llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
Modified: llvm/trunk/include/llvm/Target/TargetAsmInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Target/TargetAsmInfo.h?rev=61484&r1=61483&r2=61484&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Target/TargetAsmInfo.h (original)
+++ llvm/trunk/include/llvm/Target/TargetAsmInfo.h Mon Dec 29 16:12:11 2008
@@ -457,6 +457,11 @@
///
bool NonLocalEHFrameLabel; // Defaults to false.
+ /// Force32BitFDEReference - Force the FDE initial location and address
+ /// range to be 32-bit sized.
+ ///
+ bool Force32BitFDEReference; // Defaults to true.
+
/// GlobalEHDirective - This is the directive used to make exception frame
/// tables globally visible.
///
@@ -829,6 +834,9 @@
bool doesRequireNonLocalEHFrameLabel() const {
return NonLocalEHFrameLabel;
}
+ bool doesRequire32BitFDEReference() const {
+ return Force32BitFDEReference;
+ }
const char *getGlobalEHDirective() const {
return GlobalEHDirective;
}
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfWriter.cpp?rev=61484&r1=61483&r2=61484&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfWriter.cpp (original)
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfWriter.cpp Mon Dec 29 16:12:11 2008
@@ -3119,10 +3119,12 @@
Asm->EOL("FDE CIE offset");
- EmitReference("eh_func_begin", EHFrameInfo.Number, true);
+ EmitReference("eh_func_begin", EHFrameInfo.Number, true,
+ TAI->doesRequire32BitFDEReference());
Asm->EOL("FDE initial location");
EmitDifference("eh_func_end", EHFrameInfo.Number,
- "eh_func_begin", EHFrameInfo.Number);
+ "eh_func_begin", EHFrameInfo.Number,
+ TAI->doesRequire32BitFDEReference());
Asm->EOL("FDE address range");
// If there is a personality and landing pads then point to the language
Modified: llvm/trunk/lib/Target/TargetAsmInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/TargetAsmInfo.cpp?rev=61484&r1=61483&r2=61484&view=diff
==============================================================================
--- llvm/trunk/lib/Target/TargetAsmInfo.cpp (original)
+++ llvm/trunk/lib/Target/TargetAsmInfo.cpp Mon Dec 29 16:12:11 2008
@@ -101,6 +101,7 @@
DwarfRequiresFrameSection = true;
FDEEncodingRequiresSData4 = true;
NonLocalEHFrameLabel = false;
+ Force32BitFDEReference = true;
GlobalEHDirective = 0;
SupportsWeakOmittedEHFrame = true;
DwarfSectionOffsetDirective = 0;
Modified: llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp?rev=61484&r1=61483&r2=61484&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86TargetAsmInfo.cpp Mon Dec 29 16:12:11 2008
@@ -72,6 +72,7 @@
HasSingleParameterDotFile = false;
FDEEncodingRequiresSData4 = false;
NonLocalEHFrameLabel = true;
+ Force32BitFDEReference = false;
if (TM.getRelocationModel() == Reloc::Static) {
StaticCtorsSection = ".constructor";
StaticDtorsSection = ".destructor";
More information about the llvm-commits
mailing list