[llvm-branch-commits] [llvm-branch] r214689 - Merging r213665:

Bill Wendling isanbard at gmail.com
Sun Aug 3 21:29:47 PDT 2014


Author: void
Date: Sun Aug  3 23:29:47 2014
New Revision: 214689

URL: http://llvm.org/viewvc/llvm-project?rev=214689&view=rev
Log:
Merging r213665:
------------------------------------------------------------------------
r213665 | tnorthover | 2014-07-22 08:47:09 -0700 (Tue, 22 Jul 2014) | 11 lines

X86: drop relocations on __eh_frame sections globally.

Without this, we produce non-extern relocations when targeting older OS X
versions that ld64 can't cope with in the particular context of __eh_frame
sections (who'd want generic relocation-processing anyway?).

This means that an updated linker (ld64 from Xcode 3.2.6 or later) may be
needed when targeting such platforms with a modern version of LLVM, but this is
probably the case anyway and a reasonable requirement.

PR20212, rdar://problem/17544795
------------------------------------------------------------------------

Modified:
    llvm/branches/release_35/   (props changed)
    llvm/branches/release_35/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp
    llvm/branches/release_35/test/MC/MachO/eh-frame-reloc.s

Propchange: llvm/branches/release_35/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Aug  3 23:29:47 2014
@@ -1,3 +1,3 @@
 /llvm/branches/Apple/Pertwee:110850,110961
 /llvm/branches/type-system-rewrite:133420-134817
-/llvm/trunk:155241,213653,213726,213749,213773,213793,213798,213815,213847,213880,213883-213884,213894-213896,213899,213915,214129,214180,214287,214331,214423,214429,214519
+/llvm/trunk:155241,213653,213665,213726,213749,213773,213793,213798,213815,213847,213880,213883-213884,213894-213896,213899,213915,214129,214180,214287,214331,214423,214429,214519

Modified: llvm/branches/release_35/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_35/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp?rev=214689&r1=214688&r2=214689&view=diff
==============================================================================
--- llvm/branches/release_35/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp (original)
+++ llvm/branches/release_35/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp Sun Aug  3 23:29:47 2014
@@ -72,11 +72,10 @@ X86MCAsmInfoDarwin::X86MCAsmInfoDarwin(c
   if (T.isMacOSX() && T.isMacOSXVersionLT(10, 6))
     HasWeakDefCanBeHiddenDirective = false;
 
-  // FIXME: this should not depend on the target OS version, but on the ld64
-  // version in use.  From at least >= ld64-97.17 (Xcode 3.2.6) the abs-ified
-  // FDE relocs may be used. We also use them for the ios simulator.
-  DwarfFDESymbolsUseAbsDiff = (T.isMacOSX() && !T.isMacOSXVersionLT(10, 6))
-    || T.isiOS();
+  // Assume ld64 is new enough that the abs-ified FDE relocs may be used
+  // (actually, must, since otherwise the non-extern relocations we produce
+  // overwhelm ld64's tiny little mind and it fails).
+  DwarfFDESymbolsUseAbsDiff = true;
 
   UseIntegratedAssembler = true;
 }

Modified: llvm/branches/release_35/test/MC/MachO/eh-frame-reloc.s
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_35/test/MC/MachO/eh-frame-reloc.s?rev=214689&r1=214688&r2=214689&view=diff
==============================================================================
--- llvm/branches/release_35/test/MC/MachO/eh-frame-reloc.s (original)
+++ llvm/branches/release_35/test/MC/MachO/eh-frame-reloc.s Sun Aug  3 23:29:47 2014
@@ -1,10 +1,10 @@
 // RUN: llvm-mc < %s -triple=x86_64-apple-macosx10.7 -filetype=obj | llvm-readobj -r | FileCheck %s
 // RUN: llvm-mc < %s -triple=x86_64-apple-macosx10.6 -filetype=obj | llvm-readobj -r | FileCheck %s
 // RUN: llvm-mc < %s -triple=x86_64-apple-ios7.0.0 -filetype=obj | llvm-readobj -r | FileCheck %s
-// RUN: llvm-mc < %s -triple=x86_64-apple-macosx10.5 -filetype=obj | llvm-readobj -r | FileCheck --check-prefix=OLD64 %s
+// RUN: llvm-mc < %s -triple=x86_64-apple-macosx10.5 -filetype=obj | llvm-readobj -r | FileCheck %s
 // RUN: llvm-mc < %s -triple=i686-apple-macosx10.6 -filetype=obj | llvm-readobj -r | FileCheck %s
-// RUN: llvm-mc < %s -triple=i686-apple-macosx10.5 -filetype=obj | llvm-readobj -r | FileCheck --check-prefix=OLD32 %s
-// RUN: llvm-mc < %s -triple=i686-apple-macosx10.4 -filetype=obj | llvm-readobj -r | FileCheck --check-prefix=OLD32 %s
+// RUN: llvm-mc < %s -triple=i686-apple-macosx10.5 -filetype=obj | llvm-readobj -r | FileCheck %s
+// RUN: llvm-mc < %s -triple=i686-apple-macosx10.4 -filetype=obj | llvm-readobj -r | FileCheck %s
 
 	.globl	_bar
 	.align	4, 0x90
@@ -14,17 +14,3 @@ _bar:
 
 // CHECK:      Relocations [
 // CHECK-NEXT: ]
-
-// OLD32:      Relocations [
-// OLD32-NEXT:   Section __eh_frame {
-// OLD32-NEXT:     0x20 0 2 n/a GENERIC_RELOC_LOCAL_SECTDIFF 1 0x0
-// OLD32-NEXT:     0x0 0 2 n/a GENERIC_RELOC_PAIR 1 0x20
-// OLD32-NEXT:   }
-// OLD32-NEXT: ]
-
-// OLD64:      Relocations [
-// OLD64-NEXT:   Section __eh_frame {
-// OLD64-NEXT:     0x20 0 3 0 X86_64_RELOC_SUBTRACTOR 0
-// OLD64-NEXT:     0x20 0 3 1 X86_64_RELOC_UNSIGNED 0 _bar
-// OLD64-NEXT:   }
-// OLD64-NEXT: ]





More information about the llvm-branch-commits mailing list