This commit was manufactured by cvs2svn to create branch 'gomp-branch'.
[official-gcc.git] / gcc / testsuite / gcc.c-torture / execute / 20030916-1.c
blob8b460c6dd68399d490037c985ba76d9dc74fca52
1 /* "i" overflows in f(). Check that x[i] is not treated as a giv. */
2 #include <limits.h>
4 #if CHAR_BIT == 8
6 void f (unsigned int *x)
8 unsigned char i;
9 int j;
11 i = 0x10;
12 for (j = 0; j < 0x10; j++)
14 i += 0xe8;
15 x[i] = 0;
16 i -= 0xe7;
20 int main ()
22 unsigned int x[256];
23 int i;
25 for (i = 0; i < 256; i++)
26 x[i] = 1;
27 f (x);
28 for (i = 0; i < 256; i++)
29 if (x[i] != (i >= 0x08 && i < 0xf8))
30 abort ();
31 exit (0);
33 #else
34 int main () { exit (0); }
35 #endif