public inbox for libffi-discuss@sourceware.org
 help / color / mirror / Atom feed
* [Patch, libffi] fix (gcc) PR libffi/49594 (bootstrap fail on ppc/darwin8 with multilibs)
@ 2011-07-02 13:05 Iain Sandoe
  2011-07-02 17:17 ` Mike Stump
  0 siblings, 1 reply; 2+ messages in thread
From: Iain Sandoe @ 2011-07-02 13:05 UTC (permalink / raw)
  To: GCC Patches, libffi-discuss; +Cc: Mike Stump, Anthony Green

[-- Attachment #1: Type: text/plain, Size: 1942 bytes --]

Hi,

The bug exists on 4.6 and trunk.

The fix is pretty close to obvious.  The size of the pointer to  
dyld_stub_binding_helper needs to track m32/m64.

bootstrapped on native powerpc-apple-darwin8 on a G5 tested as below  
(using gcc-4_6-branch revision 175752).

===

Native configuration is powerpc-apple-darwin8
---

Running target unix/-m32

		=== libffi Summary for unix/-m32 ===

# of expected passes		1634
# of expected failures		10
# of unsupported tests		15

Running target unix/-m64

		=== libffi Summary for unix/-m64 ===

# of expected passes		1634
# of expected failures		10
# of unsupported tests		15

		=== libffi Summary ===

# of expected passes		3268
# of expected failures		20
# of unsupported tests		30


OK for trunk and 4.6?

Iain


Index: libffi/src/powerpc/darwin_closure.S
===================================================================
--- libffi/src/powerpc/darwin_closure.S	(revision 175752)
+++ libffi/src/powerpc/darwin_closure.S	(working copy)
@@ -534,7 +534,7 @@ L_ffi_closure_helper_DARWIN$stub:
  	.lazy_symbol_pointer
  L_ffi_closure_helper_DARWIN$lazy_ptr:
  	.indirect_symbol _ffi_closure_helper_DARWIN
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper

  #if defined(__ppc64__)
  	.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
@@ -553,7 +553,8 @@ L_darwin64_struct_ret_by_value_p$stub:
  	.lazy_symbol_pointer
  L_darwin64_struct_ret_by_value_p$lazy_ptr:
  	.indirect_symbol _darwin64_struct_ret_by_value_p
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper
+
  	.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
  	.align 5
  L_darwin64_pass_struct_floats$stub:
@@ -570,6 +571,6 @@ L_darwin64_pass_struct_floats$stub:
  	.lazy_symbol_pointer
  L_darwin64_pass_struct_floats$lazy_ptr:
  	.indirect_symbol _darwin64_pass_struct_floats
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper
  #  endif
  #endif



[-- Attachment #2: 175752-libffi-darwin-closure-pr49594-diff.txt --]
[-- Type: text/plain, Size: 1167 bytes --]

Index: libffi/src/powerpc/darwin_closure.S
===================================================================
--- libffi/src/powerpc/darwin_closure.S	(revision 175752)
+++ libffi/src/powerpc/darwin_closure.S	(working copy)
@@ -534,7 +534,7 @@ L_ffi_closure_helper_DARWIN$stub:
 	.lazy_symbol_pointer
 L_ffi_closure_helper_DARWIN$lazy_ptr:
 	.indirect_symbol _ffi_closure_helper_DARWIN
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper
 
 #if defined(__ppc64__)
 	.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
@@ -553,7 +553,8 @@ L_darwin64_struct_ret_by_value_p$stub:
 	.lazy_symbol_pointer
 L_darwin64_struct_ret_by_value_p$lazy_ptr:
 	.indirect_symbol _darwin64_struct_ret_by_value_p
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper
+
 	.section __TEXT,__picsymbolstub1,symbol_stubs,pure_instructions,32
 	.align 5
 L_darwin64_pass_struct_floats$stub:
@@ -570,6 +571,6 @@ L_darwin64_pass_struct_floats$stub:
 	.lazy_symbol_pointer
 L_darwin64_pass_struct_floats$lazy_ptr:
 	.indirect_symbol _darwin64_pass_struct_floats
-	.long	dyld_stub_binding_helper
+	.g_long	dyld_stub_binding_helper
 #  endif
 #endif

[-- Attachment #3: Type: text/plain, Size: 3 bytes --]





^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Patch, libffi] fix (gcc) PR libffi/49594 (bootstrap fail on ppc/darwin8 with multilibs)
  2011-07-02 13:05 [Patch, libffi] fix (gcc) PR libffi/49594 (bootstrap fail on ppc/darwin8 with multilibs) Iain Sandoe
@ 2011-07-02 17:17 ` Mike Stump
  0 siblings, 0 replies; 2+ messages in thread
From: Mike Stump @ 2011-07-02 17:17 UTC (permalink / raw)
  To: Iain Sandoe; +Cc: GCC Patches, libffi-discuss, Anthony Green

On Jul 2, 2011, at 6:04 AM, Iain Sandoe <developer@sandoe-acoustics.co.uk> wrote:.
> The fix is pretty close to obvious.  The size of the pointer to dyld_stub_binding_helper needs to track m32/m64.

> OK for trunk and 4.6

Ok.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-07-02 17:17 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-02 13:05 [Patch, libffi] fix (gcc) PR libffi/49594 (bootstrap fail on ppc/darwin8 with multilibs) Iain Sandoe
2011-07-02 17:17 ` Mike Stump

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).