middle-end/94988 fix testcase for big-endian
authorRichard Biener <rguenther@suse.de>
Tue, 12 May 2020 12:13:32 +0000 (14:13 +0200)
committerRichard Biener <rguenther@suse.de>
Tue, 12 May 2020 12:15:28 +0000 (14:15 +0200)
The testcase only works for little-endian, mark it so.

2020-05-12  Richard Biener  <rguenther@suse.de>

PR middle-end/94988
* gcc.dg/torture/pr94988.c: Disable runtime test for
* non-little-endian.

gcc/testsuite/gcc.dg/torture/pr94988.c

index 1ee99fea5ce0b7ba2f1d6d9cfe14d419f4d81bb4..dd523b81d993c0f3847264edb99f4524bb892731 100644 (file)
@@ -14,7 +14,9 @@ main()
 {
   b = (short *)&b;
   bar (0, 1);
+#if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
   if ((short)(__UINTPTR_TYPE__)b != 0)
     __builtin_abort ();
+#endif
   return 0;
 }