Tests gcc.target/powerpc/20020118-1.c and gcc.c-torture/execute/nest-align-1.c sometimes fail because they expect a stack alignment that is greater than that required for powerpc-eabi. This patch forces stack alignment to 128 bits by passing "-mno-eabi".
Is this OK for mainline and the 4.8 branch, or would it be better to skip these tests for powerpc-*-eabi*? Janis
2013-07-08 Janis Johnson <jani...@codesourcery.com> * gcc.target/powerpc/20020118-1.c: Force 128-bit stack alignment for EABI targets. * gcc.c-torture/execute/nest-align-1.x: Likewise. Index: gcc.target/powerpc/20020118-1.c =================================================================== --- gcc.target/powerpc/20020118-1.c (revision 200621) +++ gcc.target/powerpc/20020118-1.c (working copy) @@ -1,6 +1,8 @@ /* { dg-do run { target powerpc*-*-* } }*/ /* VxWorks only guarantees 64 bits of alignment (STACK_BOUNDARY == 64). */ /* { dg-skip-if "" { "powerpc*-*-vxworks*" } { "*" } { "" } } */ +/* Force 128-bit stack alignment for eabi targets. */ +/* { dg-options "-mno-eabi" { target powerpc*-*-eabi* } } */ /* Test local alignment. Test new target macro STARTING_FRAME_PHASE. */ /* Origin: Aldy Hernandez <al...@redhat.com>. */ Index: gcc.c-torture/execute/nest-align-1.x =================================================================== --- gcc.c-torture/execute/nest-align-1.x (revision 0) +++ gcc.c-torture/execute/nest-align-1.x (revision 0) @@ -0,0 +1,5 @@ +# Force bigger stack alignment for PowerPC EABI targets. +if { [istarget "powerpc-*-eabi*"] } { + set additional_flags "-mno-eabi" +} +return 0