From 11c26b9220dcc2becd54a81abc0fac49bcc00568 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Sat, 26 Jan 2008 09:42:33 +0000 Subject: [PATCH] 4.3.0-0.6 --- .cvsignore | 2 +- gcc43-late-visibility.patch | 23 --------- gcc43-pr31780.patch | 97 ------------------------------------- gcc43-pr32244.patch | 46 ------------------ gcc43-pr34965.patch | 6 +-- gcc43-pr34966-test.patch | 19 ++++++++ gcc43.spec | 16 +++--- sources | 2 +- 8 files changed, 30 insertions(+), 181 deletions(-) delete mode 100644 gcc43-late-visibility.patch delete mode 100644 gcc43-pr31780.patch delete mode 100644 gcc43-pr32244.patch create mode 100644 gcc43-pr34966-test.patch diff --git a/.cvsignore b/.cvsignore index 4a3ebe9..8088d61 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1,2 +1,2 @@ -gcc-4.3.0-20080125.tar.bz2 +gcc-4.3.0-20080126.tar.bz2 fastjar-0.95.tar.gz diff --git a/gcc43-late-visibility.patch b/gcc43-late-visibility.patch deleted file mode 100644 index de29ea8..0000000 --- a/gcc43-late-visibility.patch +++ /dev/null @@ -1,23 +0,0 @@ -2008-01-25 Jason Merrill - - * decl2.c (is_late_template_attribute): Don't defer attribute - visibility just because the type is dependent. - ---- gcc/cp/decl2.c (revision 131825) -+++ gcc/cp/decl2.c (revision 131833) -@@ -1014,9 +1014,12 @@ is_late_template_attribute (tree attr, t - || code == BOUND_TEMPLATE_TEMPLATE_PARM - || code == TYPENAME_TYPE) - return true; -- /* Also defer attributes on dependent types. This is not necessary -- in all cases, but is the better default. */ -- else if (dependent_type_p (type)) -+ /* Also defer most attributes on dependent types. This is not -+ necessary in all cases, but is the better default. */ -+ else if (dependent_type_p (type) -+ /* But attribute visibility specifically works on -+ templates. */ -+ && !is_attribute_p ("visibility", name)) - return true; - else - return false; diff --git a/gcc43-pr31780.patch b/gcc43-pr31780.patch deleted file mode 100644 index aeb7ed7..0000000 --- a/gcc43-pr31780.patch +++ /dev/null @@ -1,97 +0,0 @@ -2008-01-25 Jason Merrill - Mark Mitchell - - PR c++/31780 - * call.c (standard_conversion): Allow conversion from integer/real - to complex. - (compare_ics): Such a conversion is worse than a normal arithmetic - conversion. - ---- gcc/cp/call.c (revision 131825) -+++ gcc/cp/call.c (revision 131833) -@@ -846,8 +846,8 @@ standard_conversion (tree to, tree from, - } - /* We don't check for ENUMERAL_TYPE here because there are no standard - conversions to enum type. */ -- else if (tcode == INTEGER_TYPE || tcode == BOOLEAN_TYPE -- || tcode == REAL_TYPE) -+ /* As an extension, allow conversion to complex type. */ -+ else if (ARITHMETIC_TYPE_P (to)) - { - if (! (INTEGRAL_CODE_P (fcode) || fcode == REAL_TYPE)) - return NULL; -@@ -5937,6 +5937,10 @@ compare_ics (conversion *ics1, conversio - from_type2 = t2->type; - } - -+ /* One sequence can only be a subsequence of the other if they start with -+ the same type. They can start with different types when comparing the -+ second standard conversion sequence in two user-defined conversion -+ sequences. */ - if (same_type_p (from_type1, from_type2)) - { - if (is_subseq (ics1, ics2)) -@@ -5944,10 +5948,6 @@ compare_ics (conversion *ics1, conversio - if (is_subseq (ics2, ics1)) - return -1; - } -- /* Otherwise, one sequence cannot be a subsequence of the other; they -- don't start with the same type. This can happen when comparing the -- second standard conversion sequence in two user-defined conversion -- sequences. */ - - /* [over.ics.rank] - -@@ -5977,6 +5977,21 @@ compare_ics (conversion *ics1, conversio - to_type1 = ics1->type; - to_type2 = ics2->type; - -+ /* A conversion from scalar arithmetic type to complex is worse than a -+ conversion between scalar arithmetic types. */ -+ if (same_type_p (from_type1, from_type2) -+ && ARITHMETIC_TYPE_P (from_type1) -+ && ARITHMETIC_TYPE_P (to_type1) -+ && ARITHMETIC_TYPE_P (to_type2) -+ && ((TREE_CODE (to_type1) == COMPLEX_TYPE) -+ != (TREE_CODE (to_type2) == COMPLEX_TYPE))) -+ { -+ if (TREE_CODE (to_type1) == COMPLEX_TYPE) -+ return -1; -+ else -+ return 1; -+ } -+ - if (TYPE_PTR_P (from_type1) - && TYPE_PTR_P (from_type2) - && TYPE_PTR_P (to_type1) ---- gcc/testsuite/g++.dg/ext/complex3.C (revision 0) -+++ gcc/testsuite/g++.dg/ext/complex3.C (revision 131833) -@@ -0,0 +1,28 @@ -+// PR c++/31780 -+// { dg-do run } -+// { dg-options "" } -+ -+// Test that we can implicitly convert to _Complex, but that it's worse -+// than a scalar arithmetic conversion. -+ -+extern "C" void exit (int); -+ -+int r = 0; -+ -+void f (_Complex int) { ++r; } -+void f (double) { } -+ -+void g (_Complex int) { } -+ -+int main() -+{ -+ f (1); -+ g (1); -+ -+ return r; -+} -+ -+void bar() -+{ -+ r ? 0i : 0; -+} diff --git a/gcc43-pr32244.patch b/gcc43-pr32244.patch deleted file mode 100644 index e72daf6..0000000 --- a/gcc43-pr32244.patch +++ /dev/null @@ -1,46 +0,0 @@ -2008-01-25 Richard Guenther - - PR middle-end/32244 - * expr.c (expand_expr_real_1): Reduce result of LSHIFT_EXPR - to its bitfield precision if required. - - * gcc.c-torture/execute/pr32244-1.c: New testcase. - ---- gcc/expr.c (revision 131825) -+++ gcc/expr.c (revision 131833) -@@ -8920,8 +8920,11 @@ expand_expr_real_1 (tree exp, rtx target - target = 0; - op0 = expand_expr (TREE_OPERAND (exp, 0), subtarget, - VOIDmode, EXPAND_NORMAL); -- return expand_shift (code, mode, op0, TREE_OPERAND (exp, 1), target, -+ temp = expand_shift (code, mode, op0, TREE_OPERAND (exp, 1), target, - unsignedp); -+ if (code == LSHIFT_EXPR) -+ temp = REDUCE_BIT_FIELD (temp); -+ return temp; - - /* Could determine the answer when only additive constants differ. Also, - the addition of one can be handled by changing the condition. */ ---- gcc/testsuite/gcc.c-torture/execute/pr32244-1.c (revision 0) -+++ gcc/testsuite/gcc.c-torture/execute/pr32244-1.c (revision 131833) -@@ -0,0 +1,20 @@ -+struct foo -+{ -+ unsigned long long b:40; -+} x; -+ -+extern void abort (void); -+ -+void test1(unsigned long long res) -+{ -+ /* The shift is carried out in 40 bit precision. */ -+ if (x.b<<32 != res) -+ abort (); -+} -+ -+int main() -+{ -+ x.b = 0x0100; -+ test1(0); -+ return 0; -+} diff --git a/gcc43-pr34965.patch b/gcc43-pr34965.patch index 32ef0b7..6151cd2 100644 --- a/gcc43-pr34965.patch +++ b/gcc43-pr34965.patch @@ -129,7 +129,7 @@ +void +bar (int i, int j, double k) +{ -+ foo (i && j) (); // { dg-error "\\(i != 0 \\&\\& j != 0\\)" } -+ foo (!i || !j) (); // { dg-error "\\(i == 0 \\|\\| j == 0\\)" } -+ foo (!i == !j) (); // { dg-error "\\(i != 0 \\^ j == 0\\)" } ++ foo (i && j) (); // { dg-error "\\(\\(?i != 0\\)? \\&\\& \\(?j != 0\\)?\\)" } ++ foo (!i || !j) (); // { dg-error "\\(\\(?i == 0\\)? \\|\\| \\(?j == 0\\)?\\)" } ++ foo (!i == !j) (); // { dg-error "\\(\\(?i != 0\\)? \\^ \\(?j == 0\\)?\\)" } +} diff --git a/gcc43-pr34966-test.patch b/gcc43-pr34966-test.patch new file mode 100644 index 0000000..5392ef0 --- /dev/null +++ b/gcc43-pr34966-test.patch @@ -0,0 +1,19 @@ +2008-01-26 Jakub Jelinek + + * gcc.c-torture/compile/pr34966.c (atan): Only use asm + on i?86/x86_64. + +--- gcc/testsuite/gcc.c-torture/compile/pr34966.c.jj 2008-01-26 09:55:35.000000000 +0100 ++++ gcc/testsuite/gcc.c-torture/compile/pr34966.c 2008-01-26 10:00:22.000000000 +0100 +@@ -4,7 +4,11 @@ __inline double + atan (double __x) + { + register double __result; ++#if defined(__i386__) || defined(__x86_64__) + __asm __volatile__ ("" : "=t" (__result) : "0" (__x)); ++#else ++ __result = __x; ++#endif + return __result; + } + diff --git a/gcc43.spec b/gcc43.spec index 2194368..2d90e5e 100644 --- a/gcc43.spec +++ b/gcc43.spec @@ -1,4 +1,4 @@ -%define DATE 20080125 +%define DATE 20080126 %define gcc_version 4.3.0 %define gcc_release 0.6 %define _unpackaged_files_terminate_build 0 @@ -141,9 +141,7 @@ Patch11: gcc43-rh341221.patch Patch12: gcc43-cpp-pragma.patch Patch13: gcc43-java-debug-iface-type.patch Patch14: gcc43-pr34965.patch -Patch15: gcc43-late-visibility.patch -Patch16: gcc43-pr31780.patch -Patch17: gcc43-pr32244.patch +Patch15: gcc43-pr34966-test.patch # On ARM EABI systems, we do want -gnueabi to be part of the # target triple. @@ -441,9 +439,7 @@ which are required to run programs compiled with the GNAT. %patch12 -p0 -b .cpp-pragma~ %patch13 -p0 -b .java-debug-iface-type~ %patch14 -p0 -b .pr34965~ -%patch15 -p0 -b .late-visibility~ -%patch16 -p0 -b .pr31780~ -%patch17 -p0 -b .pr32244~ +%patch15 -p0 -b .pr34966-test~ tar xzf %{SOURCE4} @@ -702,8 +698,8 @@ rm -fr $RPM_BUILD_ROOT perl -pi -e \ 's~href="l(ibstdc|atest)~href="http://gcc.gnu.org/onlinedocs/libstdc++/l\1~' \ - libstdc++-v3/docs/html/documentation.html -ln -sf documentation.html libstdc++-v3/docs/html/index.html + libstdc++-v3/doc/html/documentation.html +ln -sf documentation.html libstdc++-v3/doc/html/index.html cd obj-%{gcc_target_platform} @@ -1376,7 +1372,7 @@ fi %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_version}/libstdc++.so %{_prefix}/lib/gcc/%{gcc_target_platform}/%{gcc_version}/libsupc++.a %endif -%doc rpm.doc/changelogs/libstdc++-v3/ChangeLog* libstdc++-v3/README* libstdc++-v3/docs/html/ +%doc rpm.doc/changelogs/libstdc++-v3/ChangeLog* libstdc++-v3/README* libstdc++-v3/doc/html/ %files objc %defattr(-,root,root) diff --git a/sources b/sources index e7ec685..468a387 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -011827ce044badacd7265f6abd8a473d gcc-4.3.0-20080125.tar.bz2 +c2821feee21480668a7c0449ec5ac650 gcc-4.3.0-20080126.tar.bz2 92a70f9e56223b653bce0f58f90cf950 fastjar-0.95.tar.gz