1 unsigned p;
2 
3 long __attribute__((noinline, noclone))
test(unsigned a)4 test (unsigned a)
5 {
6   return (long)(p + a) - (long)p;
7 }
8 
9 int
main()10 main ()
11 {
12   p = (unsigned) -2;
13   if (test (0) != 0)
14     __builtin_abort ();
15   if (test (1) != 1)
16     __builtin_abort ();
17   if (test (2) != -(long)(unsigned)-2)
18     __builtin_abort ();
19   p = (unsigned) -1;
20   if (test (0) != 0)
21     __builtin_abort ();
22   if (test (1) != -(long)(unsigned)-1)
23     __builtin_abort ();
24   if (test (2) != -(long)(unsigned)-2)
25     __builtin_abort ();
26   return 0;
27 }
28