[llvm-commits] [llvm-gcc-4.2] r67938 - in /llvm-gcc-4.2/branches/Apple/Dib/gcc: c-typeck.c cp/pt.c cp/typeck.c fold-const.c testsuite/ChangeLog.apple testsuite/g++.apple/asm-block-68.C version.c
Bill Wendling
isanbard at gmail.com
Sat Mar 28 03:01:51 PDT 2009
Author: void
Date: Sat Mar 28 05:01:51 2009
New Revision: 67938
URL: http://llvm.org/viewvc/llvm-project?rev=67938&view=rev
Log:
Update to Apple GCC 5644. Very small changes.
Added:
llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/g++.apple/asm-block-68.C
Modified:
llvm-gcc-4.2/branches/Apple/Dib/gcc/c-typeck.c
llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/pt.c
llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/typeck.c
llvm-gcc-4.2/branches/Apple/Dib/gcc/fold-const.c
llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/ChangeLog.apple
llvm-gcc-4.2/branches/Apple/Dib/gcc/version.c
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/c-typeck.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/c-typeck.c?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/c-typeck.c (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/c-typeck.c Sat Mar 28 05:01:51 2009
@@ -4179,8 +4179,6 @@
STRIP_TYPE_NOPS (rhs);
- newrhs = rhs;
-
/* APPLE LOCAL begin __block assign sequence point 6639533 */
/* For byref = x;, we have to transform this into {( typeof(x) x' =
x; byref = x`; )} to ensure there is a sequence point before the
@@ -4207,7 +4205,7 @@
/* then we save the rhs. */
rhs = save_expr (rhs);
if (rhs != old_rhs)
- /* And arrage for the sequence point to be inserted. */
+ /* And arrange for the sequence point to be inserted. */
insert_sequence_point = true;
}
}
@@ -4215,6 +4213,8 @@
}
/* APPLE LOCAL end __block assign sequence point 6639533 */
+ newrhs = rhs;
+
/* If a binary op has been requested, combine the old LHS value with the RHS
producing the value we should actually store into the LHS. */
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/pt.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/pt.c?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/pt.c (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/pt.c Sat Mar 28 05:01:51 2009
@@ -8752,6 +8752,26 @@
if (TREE_CODE (asm_expr) == CLEANUP_POINT_EXPR)
asm_expr = TREE_OPERAND (asm_expr, 0);
ASM_INPUT_P (asm_expr) = ASM_INPUT_P (t);
+ /* APPLE LOCAL begin inline asm labels in templates 6606502 */
+ /* We have to check to see if we have a CW style inline assembly
+ label, and mark it as defined, if this asm defines it. */
+ if (TREE_CODE (TREE_OPERAND (asm_expr, 0)) == STRING_CST
+ && TREE_STRING_LENGTH (TREE_OPERAND (asm_expr, 0)) >= 5
+ && strncmp (TREE_STRING_POINTER (TREE_OPERAND (asm_expr, 0)),
+ "%l0:", 4))
+ {
+ tree inner = TREE_OPERAND (asm_expr, 2);
+ if (inner && TREE_CODE (inner) == TREE_LIST)
+ {
+ inner = TREE_VALUE (inner);
+ if (inner && TREE_CODE (inner) == ADDR_EXPR) {
+ inner = TREE_OPERAND (inner, 0);
+ if (TREE_CODE (inner) == LABEL_DECL)
+ DECL_INITIAL (inner) = error_mark_node;
+ }
+ }
+ }
+ /* APPLE LOCAL end inline asm labels in templates 6606502 */
}
break;
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/typeck.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/typeck.c?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/typeck.c (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/cp/typeck.c Sat Mar 28 05:01:51 2009
@@ -6263,7 +6263,7 @@
/* then we save the rhs. */
rhs = save_expr (rhs);
if (rhs != old_rhs)
- /* And arrage for the sequence point to be inserted. */
+ /* And arrange for the sequence point to be inserted. */
insert_sequence_point = true;
}
}
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/fold-const.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/fold-const.c?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/fold-const.c (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/fold-const.c Sat Mar 28 05:01:51 2009
@@ -5842,9 +5842,11 @@
(C * 8) % 4 since we know that's zero. */
if ((code == TRUNC_MOD_EXPR || code == CEIL_MOD_EXPR
|| code == FLOOR_MOD_EXPR || code == ROUND_MOD_EXPR)
+ /* APPLE LOCAL begin mod overflow 6486153 */
&& (TYPE_OVERFLOW_UNDEFINED (TREE_TYPE (t))
|| (TREE_CODE (TREE_TYPE (t)) == INTEGER_TYPE
&& TYPE_IS_SIZETYPE (TREE_TYPE (t))))
+ /* APPLE LOCAL end mod overflow 6486153 */
&& TREE_CODE (TREE_OPERAND (t, 1)) == INTEGER_CST
&& integer_zerop (const_binop (TRUNC_MOD_EXPR, op1, c, 0)))
return omit_one_operand (type, integer_zero_node, op0);
@@ -10574,13 +10576,13 @@
/* bool_var != 1 becomes !bool_var. */
if (TREE_CODE (TREE_TYPE (arg0)) == BOOLEAN_TYPE && integer_onep (arg1)
&& code == NE_EXPR)
- /* APPLE LOCAL file radar 6286881 */
+ /* APPLE LOCAL radar 6286881 */
return fold_build1 (TRUTH_NOT_EXPR, type, fold_convert (type, arg0));
/* bool_var == 0 becomes !bool_var. */
if (TREE_CODE (TREE_TYPE (arg0)) == BOOLEAN_TYPE && integer_zerop (arg1)
&& code == EQ_EXPR)
- /* APPLE LOCAL file radar 6286881 */
+ /* APPLE LOCAL radar 6286881 */
return fold_build1 (TRUTH_NOT_EXPR, type, fold_convert (type, arg0));
/* ~a != C becomes a != ~C where C is a constant. Likewise for ==. */
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/ChangeLog.apple
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/ChangeLog.apple?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/ChangeLog.apple (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/ChangeLog.apple Sat Mar 28 05:01:51 2009
@@ -1,3 +1,7 @@
+2009-03-24 Stuart Hastings <stuart at apple.com>
+
+ gcc.apple/5774346.c: Add -maltivec.
+
2009-02-11 Fariborz Jahanian <fjahanian at apple.com>
Radar 6545782
Added: llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/g++.apple/asm-block-68.C
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/g%2B%2B.apple/asm-block-68.C?rev=67938&view=auto
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/g++.apple/asm-block-68.C (added)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/testsuite/g++.apple/asm-block-68.C Sat Mar 28 05:01:51 2009
@@ -0,0 +1,30 @@
+/* APPLE LOCAL file inline asm labels in templates 6606502 */
+/* { dg-do run } */
+/* { dg-options "-fasm-blocks" } */
+/* Radar 6606502 */
+
+class Foo {
+public:
+ static void dummy(){}
+};
+
+class Foo1 {
+public:
+ static void dummy(){}
+};
+
+template<class T>
+static void MyFunc() {
+ asm {
+ jmp $mylabel
+ $mylabel:
+ }
+ T::dummy();
+}
+
+int main(int argc, char** argv)
+{
+ MyFunc<Foo>();
+ MyFunc<Foo1>();
+ return 0;
+}
Modified: llvm-gcc-4.2/branches/Apple/Dib/gcc/version.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/branches/Apple/Dib/gcc/version.c?rev=67938&r1=67937&r2=67938&view=diff
==============================================================================
--- llvm-gcc-4.2/branches/Apple/Dib/gcc/version.c (original)
+++ llvm-gcc-4.2/branches/Apple/Dib/gcc/version.c Sat Mar 28 05:01:51 2009
@@ -11,12 +11,12 @@
/* APPLE LOCAL begin Apple version */
#ifdef ENABLE_LLVM
#ifdef LLVM_VERSION_INFO
-#define VERSUFFIX " (Based on Apple Inc. build 5643) (LLVM build " LLVM_VERSION_INFO ")"
+#define VERSUFFIX " (Based on Apple Inc. build 5644) (LLVM build " LLVM_VERSION_INFO ")"
#else
-#define VERSUFFIX " (Based on Apple Inc. build 5643) (LLVM build)"
+#define VERSUFFIX " (Based on Apple Inc. build 5644) (LLVM build)"
#endif
#else
-#define VERSUFFIX " (Based on Apple Inc. build 5643)"
+#define VERSUFFIX " (Based on Apple Inc. build 5644)"
#endif
/* APPLE LOCAL end Apple version */
More information about the llvm-commits
mailing list