The options specified for gcc.target/arm/fma.c and fma-sp.c can conflict
with several multilib options.  This patch skips the tests for multilibs
with conflicting options, and it adds option "-mfloat-abi=hard" which is
needed for the test.

OK for trunk?

Janis
2013-01-14  Janis Johnson  <jani...@codesourcery.com>

        * gcc.target/arm/fma.c: Skip for conflicting multilib options.
        * gcc.target/arm/fma-sp.c: Likewise.

Index: gcc.target/arm/fma.c
===================================================================
--- gcc.target/arm/fma.c        (revision 195178)
+++ gcc.target/arm/fma.c        (working copy)
@@ -1,5 +1,9 @@
 /* { dg-do compile } */
-/* { dg-options "-O2 -mcpu=cortex-a15 -mfpu=vfpv4" } */
+/* { dg-skip-if "avoid conflicts with multilib options" { ! arm_thumb2_ok } { 
"-mthumb" } { "" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { "-mcpu=*" 
} { "-mcpu=cortex-a15" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { "-mfpu=*" 
} { "-mfpu=vfpv4" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { 
"-mfloat-abi=*" } { "-mfloat-abi=hard" } } */
+/* { dg-options "-O2 -mcpu=cortex-a15 -mfpu=vfpv4 -mfloat-abi=hard" } */
 
 #include "fma.h"
 
Index: gcc.target/arm/fma-sp.c
===================================================================
--- gcc.target/arm/fma-sp.c     (revision 195178)
+++ gcc.target/arm/fma-sp.c     (working copy)
@@ -1,5 +1,9 @@
 /* { dg-do compile } */
-/* { dg-options "-O2 -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mthumb" } */
+/* { dg-skip-if "avoid conflicts with multilib options" { ! arm_thumb2_ok } { 
"-march=*" } { "" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { "-mcpu=*" 
} { "-mcpu=cortex-m4" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { "-mfpu=*" 
} { "-mfpu=fpv4-sp-d16" } } */
+/* { dg-skip-if "avoid conflicts with multilib options" { *-*-* } { 
"-mfloat-abi=*" } { "-mfloat-abi=hard" } } */
+/* { dg-options "-O2 -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mthumb 
-mfloat-abi=hard" } */
 
 #include "fma.h"
 

Reply via email to