This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] gcc.dg/vmx tests, 2 of 5
- From: Janis Johnson <janis187 at us dot ibm dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Thu, 1 Jul 2004 10:50:30 -0700
- Subject: [PATCH] gcc.dg/vmx tests, 2 of 5
Change two VMX tests that use 'long' instead of 'int' in unions with
vector types. 'int' is always 32 bits for powerpc*-*-*, but 'long' can
be 64 bits.
This is a cleanup that doesn't actually make any difference; tested with
biarch powerpc64-unknown-linux-gnu. OK for mainline?
2004-07-01 Janis Johnson <janis187@us.ibm.com>
* gcc.dg/vmx/debug-1.c: Use int, not long, in union with vector.
* gcc.dg/vmx/varargs-1.c: Use int, not long, in union with vector.
Index: gcc.dg/vmx/debug-1.c
===================================================================
RCS file: /home/janis/gcc_rsync/gcc-cvs/gcc/gcc/testsuite/gcc.dg/vmx/debug-1.c,v
retrieving revision 1.1
diff -u -p -r1.1 debug-1.c
--- gcc.dg/vmx/debug-1.c 18 Apr 2004 01:01:40 -0000 1.1
+++ gcc.dg/vmx/debug-1.c 30 Jun 2004 18:20:55 -0000
@@ -9,8 +9,8 @@ typedef union {
signed char s8[16];
unsigned short u16[8];
signed short s16[8];
- unsigned long u32[4];
- signed long s32[4];
+ unsigned int u32[4];
+ signed int s32[4];
float f32[4];
} U;
U u;
Index: gcc.dg/vmx/varargs-1.c
===================================================================
RCS file: /home/janis/gcc_rsync/gcc-cvs/gcc/gcc/testsuite/gcc.dg/vmx/varargs-1.c,v
retrieving revision 1.2
diff -u -p -r1.2 varargs-1.c
--- gcc.dg/vmx/varargs-1.c 18 Apr 2004 12:57:15 -0000 1.2
+++ gcc.dg/vmx/varargs-1.c 30 Jun 2004 18:20:55 -0000
@@ -13,10 +13,10 @@ void printx(T a)
{
union {
T v;
- unsigned long a[4];
+ unsigned int a[4];
} u;
u.v = a;
- printf("%ld, %ld, %ld, %ld\n", u.a[0], u.a[1], u.a[2], u.a[3]);
+ printf("%d, %d, %d, %d\n", u.a[0], u.a[1], u.a[2], u.a[3]);
}
void f1(int a, ...)