[llvm-commits] [llvm-gcc-4.2] r54188 - in /llvm-gcc-4.2/trunk/gcc: c-cppbuiltin.c toplev.c tree-gimple.c

Bill Wendling isanbard at gmail.com
Tue Jul 29 17:42:05 PDT 2008


Author: void
Date: Tue Jul 29 19:42:05 2008
New Revision: 54188

URL: http://llvm.org/viewvc/llvm-project?rev=54188&view=rev
Log:
More merges with Apple's GCC 4.2

Modified:
    llvm-gcc-4.2/trunk/gcc/c-cppbuiltin.c
    llvm-gcc-4.2/trunk/gcc/toplev.c
    llvm-gcc-4.2/trunk/gcc/tree-gimple.c

Modified: llvm-gcc-4.2/trunk/gcc/c-cppbuiltin.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/c-cppbuiltin.c?rev=54188&r1=54187&r2=54188&view=diff

==============================================================================
--- llvm-gcc-4.2/trunk/gcc/c-cppbuiltin.c (original)
+++ llvm-gcc-4.2/trunk/gcc/c-cppbuiltin.c Tue Jul 29 19:42:05 2008
@@ -368,13 +368,12 @@
   else
     builtin_define_with_value_n ("__GNUC_PATCHLEVEL__", "0", 1);
 
-  gcc_assert (!*v || *v == ' ' || *v == '-' || *v == '(');
+  gcc_assert (!*v || *v == ' ' || *v == '-');
 
   /* LLVM LOCAL no version number */
 #ifndef LLVM_VERSION_INFO
 
   /* APPLE LOCAL begin Apple version */
-#ifdef CONFIG_DARWIN_H
   {
     /* This chunk of code defines __APPLE_CC__ from the version
        string.  It expects to see a substring of the version string of
@@ -398,7 +397,6 @@
       abort ();
     builtin_define_with_value_n ("__APPLE_CC__", vt, q - vt);
   }
-#endif
   /* APPLE LOCAL end Apple version */
 
   /* LLVM LOCAL begin version number */
@@ -474,7 +472,6 @@
     return;
 
   define__GNUC__ ();
-  
   /* LLVM LOCAL begin */
 #ifdef ENABLE_LLVM
   cpp_define (pfile, "__llvm__");
@@ -585,6 +582,11 @@
 
   /* Other target-independent built-ins determined by command-line
      options.  */
+  /* APPLE LOCAL begin blocks */
+  /* APPLE LOCAL radar 5868913 */
+  if (flag_blocks && !c_dialect_cxx ())
+    cpp_define (pfile, "__BLOCKS__=1"); 
+  /* APPLE LOCAL end blocks */
   if (optimize_size)
     cpp_define (pfile, "__OPTIMIZE_SIZE__");
   if (optimize)

Modified: llvm-gcc-4.2/trunk/gcc/toplev.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/toplev.c?rev=54188&r1=54187&r2=54188&view=diff

==============================================================================
--- llvm-gcc-4.2/trunk/gcc/toplev.c (original)
+++ llvm-gcc-4.2/trunk/gcc/toplev.c Tue Jul 29 19:42:05 2008
@@ -84,7 +84,9 @@
 #include "tree-mudflap.h"
 
 /* LLVM LOCAL begin */
+#ifdef ENABLE_LLVM
 #include "llvm.h"
+#endif
 /* LLVM LOCAL end */
 
 #if defined (DWARF2_UNWIND_INFO) || defined (DWARF2_DEBUGGING_INFO)

Modified: llvm-gcc-4.2/trunk/gcc/tree-gimple.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/tree-gimple.c?rev=54188&r1=54187&r2=54188&view=diff

==============================================================================
--- llvm-gcc-4.2/trunk/gcc/tree-gimple.c (original)
+++ llvm-gcc-4.2/trunk/gcc/tree-gimple.c Tue Jul 29 19:42:05 2008
@@ -157,6 +157,7 @@
 }
 
 /* LLVM LOCAL begin */
+#ifdef ENABLE_LLVM
 static inline bool
 llvm_is_array_arrayref_extension(tree t)
 {
@@ -170,6 +171,7 @@
 #endif
   return false;
 }
+#endif
 /* LLVM LOCAL end */
 
 /*  Return true if T is something whose address can be taken.  */
@@ -178,8 +180,11 @@
 is_gimple_addressable (tree t)
 {
   return (is_gimple_id (t) || handled_component_p (t)
-          /* LLVM LOCAL */
+          /* LLVM LOCAL begin */
+#ifdef ENABLE_LLVM
           || llvm_is_array_arrayref_extension (t)
+#endif
+          /* LLVM LOCAL end */
 	  || INDIRECT_REF_P (t));
 }
 





More information about the llvm-commits mailing list