This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[testsuite] backport test fixes to 4.3 branch
- From: Janis Johnson <janis187 at us dot ibm dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Tue, 02 Dec 2008 14:13:49 -0800
- Subject: [testsuite] backport test fixes to 4.3 branch
- Reply-to: janis187 at us dot ibm dot com
I checked in backports for several test fixes to the 4.3 branch.
2008-12-02 Janis Johnson <janis187@us.ibm.com>
Backport from mainline:
2008-08-26 Janis Johnson <janis187@us.ibm.com>
* gcc.dg/Wstrict-aliasing-bogus-ref-all-2.c: Ignore a warning.
* g++.dg/ext/altivec-3.C: Move AltiVec code out of main.
Backport from mainline:
2008-07-10 2008-07-10 Joseph Myers <joseph@codesourcery.com>
PR middle-end/29056
* gcc.target/powerpc/ppc-negeq0-1.c: Use long instead of int.
Adjust shift and scan-assembler-not pattern to allow for 64-bit
case.
Backport from mainline:
2008-06-09 Joseph Myers <joseph@codesourcery.com>
* gcc.dg/pr34856.c: Condition use of -maltivec on
powerpc_altivec_ok. Use -w on other powerpc*-*-linux*.
Backport from mainline:
2008-05-20 Janis Johnson <janis187@us.ibm.com>
* g++.dg/ext/vector14.C: Ignore a possible warning.
Backport from mainline:
2008-04-21 Steve Ellcey <sje@cup.hp.com>
* gcc.dg/vect/pr33953.c: XFAIL if vect_no_align.
Backport from mainline:
2008-04-04 Janis Johnson <janis187@us.ibm.com>
* gcc.dg/var-expand3.c: Skip for powerpc-linux if not on AltiVec HW.
* gcc.dg/torture/builtin-modf-1.c: Use special options for
powerpc*-*-linux*.
Backport from mainline:
2008-04-04 Janis Johnson <janis187@us.ibm.com>
* g++.dg/other/anon5.C: Don't depend on line number for error message.
Index: gcc/testsuite/gcc.dg/Wstrict-aliasing-bogus-ref-all-2.c
===================================================================
--- gcc/testsuite/gcc.dg/Wstrict-aliasing-bogus-ref-all-2.c (revision 142371)
+++ gcc/testsuite/gcc.dg/Wstrict-aliasing-bogus-ref-all-2.c (working copy)
@@ -22,3 +22,5 @@
return ret;
}
+/* Ignore a warning that is irrelevant to the purpose of this test. */
+/* { dg-prune-output ".*GCC vector returned by reference.*" } */
Index: gcc/testsuite/g++.dg/ext/altivec-3.C
===================================================================
--- gcc/testsuite/g++.dg/ext/altivec-3.C (revision 142371)
+++ gcc/testsuite/g++.dg/ext/altivec-3.C (working copy)
@@ -120,16 +120,19 @@
CHECK_INVARIANT (vec_all_eq (vxi.v, vx_g.v));
}
-int main(void)
+void main1(void)
{
CHECK_INVARIANT (sizeof(struct foo) == 8 && sizeof(struct vfoo) == 48);
- altivec_check();
-
bar(i_1, x_g, (short)i_2, (float)d_2, ld_1, (char)i_1, d_3);
baz(i_1, v_g, i_1, vx_g, i_1, v2_g, i_1, vx2_g);
quux(i_1, v_g, v_g);
baz2(i_1, vx_g);
-
+}
+
+int main(void)
+{
+ altivec_check();
+ main1();
return 0;
}
Index: gcc/testsuite/gcc.target/powerpc/ppc-negeq0-1.c
===================================================================
--- gcc/testsuite/gcc.target/powerpc/ppc-negeq0-1.c (revision 142371)
+++ gcc/testsuite/gcc.target/powerpc/ppc-negeq0-1.c (working copy)
@@ -1,15 +1,15 @@
/* { dg-do compile } */
/* { dg-options "-O2" } */
-int foo(int x)
+long foo(long x)
{
return -(x == 0);
}
-int bar(int x)
+long bar(long x)
{
- int t = __builtin_clz(x);
- return -(t>>5);
+ long t = __builtin_clzl(x);
+ return -(t>>(sizeof(long) == 8 ? 6 : 5));
}
-/* { dg-final { scan-assembler-not "cntlzw" } } */
+/* { dg-final { scan-assembler-not "cntlz" } } */
Index: gcc/testsuite/gcc.dg/pr34856.c
===================================================================
--- gcc/testsuite/gcc.dg/pr34856.c (revision 142371)
+++ gcc/testsuite/gcc.dg/pr34856.c (working copy)
@@ -1,6 +1,8 @@
/* { dg-do compile } */
/* { dg-options "-O2" } */
/* { dg-options "-O2 -msse2" { target { i?86-*-* x86_64-*-* } } } */
+/* { dg-options "-O2 -w" { target { powerpc*-*-linux* } } } */
+/* { dg-options "-O2 -maltivec" { target { powerpc*-*-linux* && powerpc_altivec_ok } } } */
typedef unsigned __attribute__ ((__mode__ (__pointer__))) uintptr_t;
Index: gcc/testsuite/g++.dg/ext/vector14.C
===================================================================
--- gcc/testsuite/g++.dg/ext/vector14.C (revision 142371)
+++ gcc/testsuite/g++.dg/ext/vector14.C (working copy)
@@ -1,6 +1,8 @@
// PR c++/35758
// { dg-do compile }
// { dg-options "-msse" { target { { i?86-*-* x86_64-*-* } && ilp32 } } } */
+// Ignore warning on some powerpc-linux configurations.
+// { dg-prune-output "non-standard ABI extension" }
#define vector __attribute__((vector_size(16)))
Index: gcc/testsuite/gcc.dg/vect/pr33953.c
===================================================================
--- gcc/testsuite/gcc.dg/vect/pr33953.c (revision 142371)
+++ gcc/testsuite/gcc.dg/vect/pr33953.c (working copy)
@@ -28,8 +28,8 @@
}
}
-/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
-/* { dg-final { scan-tree-dump-times "vectorizing stmts using SLP" 1 "vect" } } */
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { xfail vect_no_align } } } */
+/* { dg-final { scan-tree-dump-times "vectorizing stmts using SLP" 1 "vect" { xfail vect_no_align } } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
Index: gcc/testsuite/gcc.dg/var-expand3.c
===================================================================
--- gcc/testsuite/gcc.dg/var-expand3.c (revision 142371)
+++ gcc/testsuite/gcc.dg/var-expand3.c (working copy)
@@ -1,4 +1,4 @@
-/* { dg-do run { target { powerpc*-*-* && powerpc_altivec_ok } } }} */
+/* { dg-do run { target { powerpc*-*-* && vmx_hw } } }} */
/* { dg-options "-O2 -funroll-loops -ffast-math -fvariable-expansion-in-unroller -maltivec -dL" } */
#include "altivec.h"
Index: gcc/testsuite/gcc.dg/torture/builtin-modf-1.c
===================================================================
--- gcc/testsuite/gcc.dg/torture/builtin-modf-1.c (revision 142371)
+++ gcc/testsuite/gcc.dg/torture/builtin-modf-1.c (working copy)
@@ -7,7 +7,7 @@
/* { dg-do link } */
/* { dg-options "-fno-finite-math-only" { target sh*-*-* } } */
-/* { dg-options "-funsafe-math-optimizations -fsigned-zeros -fno-associative-math" { target powerpc-*-darwin* } } */
+/* { dg-options "-funsafe-math-optimizations -fsigned-zeros -fno-associative-math" { target powerpc-*-darwin* powerpc*-*-linux* } } */
extern void link_error(int);
Index: gcc/testsuite/g++.dg/other/anon5.C
===================================================================
--- gcc/testsuite/g++.dg/other/anon5.C (revision 142371)
+++ gcc/testsuite/g++.dg/other/anon5.C (working copy)
@@ -16,7 +16,9 @@
const bool &f()
{
- return c::t; // { dg-error "undefined" }
+ return c::t; // { dg-error "undefined" "undefined" { target *-*-* } 0 }
+ // Some targets report the error for the previous line, others
+ // don't give line number information for it, so use line 0.
}
int main(void)