This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] PR41288 Preserve stack alignment in asm-support-darwin.s


The attached patch implements the same fix that was used for PR39907
to eliminate the failures in the gcc.target/x86_64/abi/test_struct_returning.c 
testcase on *-apple-darwin* at -m64. Tested on x86_64-apple-darwin10.
Okay for gcc trunk?
                 Jack

2009-09-08  Jack Howarth  <howarth@bromo.med.uc.edu>

        PR testsuite/41288
	* gcc.target/x86_64/abi/asm-support-darwin.s (snapshot_ret): Preserve
	stack alignment.

Index: gcc/testsuite/gcc.target/x86_64/abi/asm-support-darwin.s
===================================================================
--- gcc/testsuite/gcc.target/x86_64/abi/asm-support-darwin.s	(revision 151538)
+++ gcc/testsuite/gcc.target/x86_64/abi/asm-support-darwin.s	(working copy)
@@ -42,7 +42,9 @@
 .globl _snapshot_ret
 _snapshot_ret:
 	movq	%rdi, _rdi(%rip)
+	subq	$8, %rsp
 	call	*_callthis(%rip)
+	addq	$8, %rsp
 	movq	%rax, _rax(%rip)
 	movq	%rdx, _rdx(%rip)
 	movdqu	%xmm0, _xmm_regs+0(%rip)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]