[committed] Fix two pastos in guality/rotatetest.c

Jakub Jelinek jakub@redhat.com
Sat Jun 4 06:10:00 GMT 2011


Hi!

f4/f5/f6 were copied from f1/f2/f3, just with s/long/int/,
but only in f4 I've adjusted the shift count.
Fixed thusly, committed to trunk.

2011-06-04  Jakub Jelinek  <jakub@redhat.com>

	* gcc.dg/guality/rotatetest.c (f5, f6): Fix up pastos.

--- gcc/testsuite/gcc.dg/guality/rotatetest.c	(revision 174631)
+++ gcc/testsuite/gcc.dg/guality/rotatetest.c	(working copy)
@@ -46,7 +46,7 @@ f4 (unsigned int x)
 __attribute__((noclone, noinline)) unsigned int
 f5 (unsigned int x, int y)
 {
-  unsigned int f = (x << y) | (x >> (64 - y));
+  unsigned int f = (x << y) | (x >> (32 - y));
   unsigned int g = f;
   asm volatile ("" : "+r" (f));
   vv++;		/* { dg-final { gdb-test 52 "g" "f" } } */
@@ -56,7 +56,7 @@ f5 (unsigned int x, int y)
 __attribute__((noclone, noinline)) unsigned int
 f6 (unsigned int x, int y)
 {
-  unsigned int f = (x >> y) | (x << (64 - y));
+  unsigned int f = (x >> y) | (x << (32 - y));
   unsigned int g = f;
   asm volatile ("" : "+r" (f));
   vv++;		/* { dg-final { gdb-test 62 "g" "f" } } */

	Jakub



More information about the Gcc-patches mailing list