pr81875.c 598 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /* { dg-do run } */
  2. extern
  3. #ifdef __cplusplus
  4. "C"
  5. #endif
  6. void abort (void);
  7. #define N 32ULL
  8. int a[N];
  9. const unsigned long long c = 0x7fffffffffffffffULL;
  10. void
  11. f2_tpf_static32 (void)
  12. {
  13. unsigned long long i;
  14. #pragma omp for
  15. for (i = c + N; i > c; i -= 1ULL)
  16. a[i - 1ULL - c] -= 4;
  17. }
  18. __attribute__((noinline, noclone)) int
  19. test_tpf_static32 (void)
  20. {
  21. int i, j, k;
  22. for (i = 0; i < N; i++)
  23. a[i] = i - 25;
  24. f2_tpf_static32 ();
  25. for (i = 0; i < N; i++)
  26. if (a[i] != i - 29)
  27. return 1;
  28. return 0;
  29. }
  30. int
  31. main ()
  32. {
  33. if (test_tpf_static32 ())
  34. abort ();
  35. return 0;
  36. }