summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.c-torture/execute/pr39233.c
blob: 29f722395cfa7a803802b04eae34c8162c94dc1c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
extern void abort (void);

__attribute__((noinline)) void
foo (void *p)
{
  long l = (long) p;
  if (l < 0 || l > 6)
    abort ();
}

int
main ()
{
  short i;
  for (i = 6; i >= 0; i--)
    foo ((void *) (long) i);
  return 0;
}