[llvm-commits] [llvm-gcc-4.0] r42353 - in /llvm-gcc-4.0/trunk/gcc: config/alpha/unicosmk.h config/darwin.h objc/objc-act.c
Anton Korobeynikov
asl at math.spbu.ru
Wed Sep 26 02:06:00 PDT 2007
Author: asl
Date: Wed Sep 26 04:05:59 2007
New Revision: 42353
URL: http://llvm.org/viewvc/llvm-project?rev=42353&view=rev
Log:
Unbreak objc on non-darwin
Modified:
llvm-gcc-4.0/trunk/gcc/config/alpha/unicosmk.h
llvm-gcc-4.0/trunk/gcc/config/darwin.h
llvm-gcc-4.0/trunk/gcc/objc/objc-act.c
Modified: llvm-gcc-4.0/trunk/gcc/config/alpha/unicosmk.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.0/trunk/gcc/config/alpha/unicosmk.h?rev=42353&r1=42352&r2=42353&view=diff
==============================================================================
--- llvm-gcc-4.0/trunk/gcc/config/alpha/unicosmk.h (original)
+++ llvm-gcc-4.0/trunk/gcc/config/alpha/unicosmk.h Wed Sep 26 04:05:59 2007
@@ -96,7 +96,7 @@
/* The stack frame grows downward. */
-#define FRAME_GROWS_DOWNWARD
+#define FRAME_GROWS_DOWNWARD 1
/* Define the offset between two registers, one to be eliminated, and the
other its replacement, at the start of a routine. This is somewhat
Modified: llvm-gcc-4.0/trunk/gcc/config/darwin.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.0/trunk/gcc/config/darwin.h?rev=42353&r1=42352&r2=42353&view=diff
==============================================================================
--- llvm-gcc-4.0/trunk/gcc/config/darwin.h (original)
+++ llvm-gcc-4.0/trunk/gcc/config/darwin.h Wed Sep 26 04:05:59 2007
@@ -790,6 +790,20 @@
error ("Mac OS X version 10.5 or later is needed for zerocost-exceptions"); \
} while (0)
/* APPLE LOCAL end radar 5023725 */
+
+/* LLVM LOCAL begin */
+/* APPLE LOCAL begin radar 4590191 */
+#undef OBJC_FLAG_SJLJ_EXCEPTIONS
+#define OBJC_FLAG_SJLJ_EXCEPTIONS \
+ do { \
+ if (darwin_macosx_version_min \
+ && strverscmp (darwin_macosx_version_min, "10.3") < 0) \
+ warning (0, "Mac OS X version 10.3 or later is needed instead of %s for objc/obj-c++ exceptions", \
+ darwin_macosx_version_min); \
+ } while(0)
+/* APPLE LOCAL end radar 4590191 */
+/* LLVM LOCAL end */
+
/* APPLE LOCAL begin radar 4862848 */
#undef OBJC_FLAG_OBJC_ABI
#define OBJC_FLAG_OBJC_ABI \
Modified: llvm-gcc-4.0/trunk/gcc/objc/objc-act.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.0/trunk/gcc/objc/objc-act.c?rev=42353&r1=42352&r2=42353&view=diff
==============================================================================
--- llvm-gcc-4.0/trunk/gcc/objc/objc-act.c (original)
+++ llvm-gcc-4.0/trunk/gcc/objc/objc-act.c Wed Sep 26 04:05:59 2007
@@ -124,6 +124,13 @@
#ifndef OBJC_FLAG_ZEROCOST_EXCEPTIONS
#define OBJC_FLAG_ZEROCOST_EXCEPTIONS
#endif
+/* LLVM LOCAL begin */
+/* APPLE LOCAL begin radar 4590191 */
+#ifndef OBJC_FLAG_SJLJ_EXCEPTIONS
+#define OBJC_FLAG_SJLJ_EXCEPTIONS
+#endif
+/* APPLE LOCAL end radar 4590191 */
+/* LLVM LOCAL end */
/* APPLE LOCAL end radar 5023725 */
/* APPLE LOCAL begin radar 4531086 */
#ifndef OBJC_WARN_OBJC2_FEATURES
@@ -7638,10 +7645,9 @@
/* APPLE LOCAL begin radar 4590191 */
if (flag_objc_sjlj_exceptions)
{
- if (darwin_macosx_version_min
- && strverscmp (darwin_macosx_version_min, "10.3") < 0)
- warning ("Mac OS X version 10.3 or later is needed instead of %s for objc/obj-c++ exceptions",
- darwin_macosx_version_min);
+ /* LLVM LOCAL begin */
+ OBJC_FLAG_SJLJ_EXCEPTIONS;
+ /* LLVM LOCAL end */
/* APPLE LOCAL end radar 4590191 */
/* APPLE LOCAL radar 4512786. */
/* code removed */
@@ -18151,7 +18157,7 @@
set_user_assembler_name(decl, string);
/* Let optimizer know that this decl is not removable. */
DECL_PRESERVE_P (decl) = 1;
-#endif ENABLE_LLVM
+#endif
/* APPLE LOCAL end LLVM */
pushdecl (decl);
@@ -18170,7 +18176,7 @@
/* This decl's name is special. Ask llvm to not add leading underscore by
setting it as a user supplied asm name. */
set_user_assembler_name(decl, string);
-#endif ENABLE_LLVM
+#endif
/* APPLE LOCAL end LLVM */
pushdecl (decl);
@@ -18254,7 +18260,7 @@
set_user_assembler_name(decl, string);
/* Let optimizer know that this decl is not removable. */
DECL_PRESERVE_P (decl) = 1;
-#endif ENABLE_LLVM
+#endif
/* APPLE LOCAL end LLVM */
DECL_INITIAL (decl) = init;
assemble_variable (decl, 1, 0, 0);
@@ -18317,7 +18323,7 @@
/* Let optimizer know that this decl is not removable. */
set_user_assembler_name(decl, IDENTIFIER_POINTER (DECL_NAME(decl)));
DECL_PRESERVE_P (decl) = 1;
-#endif ENABLE_LLVM
+#endif
/* APPLE LOCAL end LLVM */
assemble_variable (decl, 1, 0, 0);
}
More information about the llvm-commits
mailing list