This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH,testsuite] fix altivec-macros.c for non-altivec targets
- From: Nathan Froyd <froydnj at codesourcery dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: janis187 at us dot ibm dot com
- Date: Tue, 13 Jan 2009 06:53:51 -0800
- Subject: [PATCH,testsuite] fix altivec-macros.c for non-altivec targets
gcc.target/powerpc/altivec-macros.c needs to require an effective target
with altivec; otherwise we get spurious failures on SPE targets. The
patch is big because we have to adjust the line numbers for all the
error messages accordingly.
Tested on powerpc-none-eabi{,spe}. OK to commit?
-Nathan
2009-01-13 Nathan Froyd <froydnj@codesourcery.com>
* gcc.target/powerpc/altivec-macros.c: Require a powerpc_altivec_ok
effective target. Adjust line numbers accordingly.
Index: gcc.target/powerpc/altivec-macros.c
===================================================================
--- gcc.target/powerpc/altivec-macros.c (revision 143338)
+++ gcc.target/powerpc/altivec-macros.c (working copy)
@@ -1,6 +1,7 @@
/* Copyright (C) 2007 Free Software Foundation, Inc. */
/* { dg-do preprocess } */
+/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-options "-maltivec" } */
/* Conditional macros should not be expanded by pragmas. */
@@ -48,16 +49,16 @@ _Pragma ("__vector")
#define pixel newer_pixel
#define bool newer_bool
-/* { dg-warning "redefined" "__vector redefined" { target *-*-* } 44 } */
-/* { dg-warning "redefined" "__pixel redefined" { target *-*-* } 45 } */
-/* { dg-warning "redefined" "__bool redefined" { target *-*-* } 46 } */
-/* { dg-warning "redefined" "vector redefined" { target *-*-* } 47 } */
-/* { dg-warning "redefined" "pixel redefined" { target *-*-* } 48 } */
-/* { dg-warning "redefined" "bool redefined" { target *-*-* } 49 } */
-
-/* { dg-message "location of the previous" "prev __vector defn" { target *-*-* } 24 } */
-/* { dg-message "location of the previous" "prev __pixel defn" { target *-*-* } 27 } */
-/* { dg-message "location of the previous" "prev __bool defn" { target *-*-* } 30 } */
-/* { dg-message "location of the previous" "prev vector defn" { target *-*-* } 33 } */
-/* { dg-message "location of the previous" "prev pixel defn" { target *-*-* } 36 } */
-/* { dg-message "location of the previous" "prev bool defn" { target *-*-* } 39 } */
+/* { dg-warning "redefined" "__vector redefined" { target *-*-* } 45 } */
+/* { dg-warning "redefined" "__pixel redefined" { target *-*-* } 46 } */
+/* { dg-warning "redefined" "__bool redefined" { target *-*-* } 47 } */
+/* { dg-warning "redefined" "vector redefined" { target *-*-* } 48 } */
+/* { dg-warning "redefined" "pixel redefined" { target *-*-* } 49 } */
+/* { dg-warning "redefined" "bool redefined" { target *-*-* } 50 } */
+
+/* { dg-message "location of the previous" "prev __vector defn" { target *-*-* } 25 } */
+/* { dg-message "location of the previous" "prev __pixel defn" { target *-*-* } 28 } */
+/* { dg-message "location of the previous" "prev __bool defn" { target *-*-* } 31 } */
+/* { dg-message "location of the previous" "prev vector defn" { target *-*-* } 34 } */
+/* { dg-message "location of the previous" "prev pixel defn" { target *-*-* } 37 } */
+/* { dg-message "location of the previous" "prev bool defn" { target *-*-* } 40 } */