OSDN Git Service

* gcc.c-torture/compile/20010327-1.c: Back out last change. Add
authorgeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 3 Mar 2003 19:02:28 +0000 (19:02 +0000)
committergeoffk <geoffk@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 3 Mar 2003 19:02:28 +0000 (19:02 +0000)
comment explaining purpose of testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@63726 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/20010327-1.c

index 3388db2..68479e7 100644 (file)
@@ -1,3 +1,8 @@
+2003-03-03  Geoffrey Keating  <geoffk@apple.com>
+
+       * gcc.c-torture/compile/20010327-1.c: Back out last change.  Add
+       comment explaining purpose of testcase.
+
 2003-03-02  Stephane Carrez  <stcarrez@nerim.fr>
 
        * gcc.c-torture/execute/960312-1.x: New file, must pass -mshort
index 711cd71..10f7e39 100644 (file)
@@ -1,6 +1,9 @@
+/* This testcase tests whether GCC can produce static initialized data
+   that references addresses of size 'unsigned long', even if that's not
+   the same as __SIZE_TYPE__.  (See 20011114-1.c for the same test of
+   size __SIZE_TYPE__.)  
+
+   Some rare environments might not have the required relocs to support
+   this; they should have this test disabled in the .x file.  */
 extern void _text;
-/* We use __SIZE_TYPE__ here because it's as wide as a pointer, so we
-   know we won't have a non-constant because of extension or
-   truncation of the pointer to fit.  */
-static __SIZE_TYPE__ x
-  = (__SIZE_TYPE__) &_text - (__SIZE_TYPE__) 0x10000000L - 1;
+static unsigned long x = (unsigned long) &_text - 0x10000000L - 1;