diff mbox

[RFA/testsuite] Use rand instead of random (again)

Message ID 4ED6386A.3090203@arm.com
State New
Headers show

Commit Message

Matthew Gretton-Dann Nov. 30, 2011, 2:06 p.m. UTC
All,

The attached patch changes another use of random in the testsuite to rand.

Tested on an arm-none-eabi target using QEmu.

Please can someone review.

Thanks,

Matt

gcc/testsuite/ChangeLog:

2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>

	* gcc.dg/torture/vec-cvt-1.c (FLTTEST): Call rand instead of
	random.

Comments

Mike Stump Dec. 4, 2011, 7:45 a.m. UTC | #1
On Nov 30, 2011, at 6:06 AM, Matthew Gretton-Dann wrote:
> The attached patch changes another use of random in the testsuite to rand.

> Please can someone review.

Ok?  is the canonical spelling for this...  :-)

Ok.  (is the canonical answer.)

> 2011-11-30  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
> 
> 	* gcc.dg/torture/vec-cvt-1.c (FLTTEST): Call rand instead of
> 	random.
diff mbox

Patch

diff --git a/gcc/testsuite/gcc.dg/torture/vec-cvt-1.c b/gcc/testsuite/gcc.dg/torture/vec-cvt-1.c
index 601f098..4354237 100644
--- a/gcc/testsuite/gcc.dg/torture/vec-cvt-1.c
+++ b/gcc/testsuite/gcc.dg/torture/vec-cvt-1.c
@@ -104,9 +104,9 @@  flttointtest##intt (void)						\
       abort ();								\
   for (i = 0; i < N; i++)						\
     {									\
-      unsigned long long r = random ();					\
-      r = (r << 21) ^ (unsigned) random ();				\
-      r = (r << 21) ^ (unsigned) random ();				\
+      unsigned long long r = rand ();					\
+      r = (r << 21) ^ (unsigned) rand ();				\
+      r = (r << 21) ^ (unsigned) rand ();				\
       asm ("");								\
       f[i] = (r >> 59) / 32.0f + (__typeof (intt[0])) r;		\
       if (f[i] < fltmin) f[i] = fltmin;					\
@@ -157,9 +157,9 @@  inttoflttest##intt (void)						\
     }									\
   for (i = 0; i < N; i++)						\
     {									\
-      unsigned long long r = random ();					\
-      r = (r << 21) ^ (unsigned) random ();				\
-      r = (r << 21) ^ (unsigned) random ();				\
+      unsigned long long r = rand ();					\
+      r = (r << 21) ^ (unsigned) rand ();				\
+      r = (r << 21) ^ (unsigned) rand ();				\
       asm ("");								\
       intt[i] = r;							\
     }									\