Commit fe644092 by Nick Clifton Committed by Nick Clifton

Fix test to work with 16-bit targets

From-SVN: r128903
parent 0999159b
2007-10-01 Nick Clifton <nickc@redhat.com>
* gcc.c-torture/execute/20060102-1.c (f): Fix computation to work
for 16-bit targets.
2007-09-30 Diego Novillo <dnovillo@google.com>
PR 33593
......@@ -2,7 +2,7 @@ extern void abort ();
int f(int x)
{
return (x >> 31) ? -1 : 1;
return (x >> (sizeof (x) * __CHAR_BIT__ - 1)) ? -1 : 1;
}
volatile int one = 1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment