diff --git a/.cvsignore b/.cvsignore index 385766e..bd7d39d 100644 --- a/.cvsignore +++ b/.cvsignore @@ -1 +1 @@ -gcc-4.1.1-20060926.tar.bz2 +gcc-4.1.1-20060928.tar.bz2 diff --git a/gcc41-pr29272.patch b/gcc41-pr29272.patch new file mode 100644 index 0000000..00ff7b5 --- /dev/null +++ b/gcc41-pr29272.patch @@ -0,0 +1,74 @@ +2006-09-28 Jakub Jelinek + + PR middle-end/29272 + * builtins.c (fold_builtin_memset, fold_builtin_memory_op): Restrict + single entry optimization to variables and components thereof. + +--- gcc/builtins.c.jj 2006-09-22 10:29:55.000000000 +0200 ++++ gcc/builtins.c 2006-09-28 20:31:30.000000000 +0200 +@@ -7905,7 +7905,7 @@ fold_builtin_exponent (tree fndecl, tree + static tree + fold_builtin_memset (tree arglist, tree type, bool ignore) + { +- tree dest, c, len, var, ret; ++ tree dest, c, len, var, ret, inner; + unsigned HOST_WIDE_INT length, cval; + + if (!validate_arglist (arglist, +@@ -7939,6 +7939,15 @@ fold_builtin_memset (tree arglist, tree + && !POINTER_TYPE_P (TREE_TYPE (var))) + return 0; + ++ /* If var is a VAR_DECL or a component thereof, ++ we can use its alias set, otherwise we'd need to make ++ sure we go through alias set 0. */ ++ inner = var; ++ while (handled_component_p (inner)) ++ inner = TREE_OPERAND (inner, 0); ++ if (! SSA_VAR_P (inner)) ++ return 0; ++ + length = tree_low_cst (len, 1); + if (GET_MODE_SIZE (TYPE_MODE (TREE_TYPE (var))) != length + || get_pointer_alignment (dest, BIGGEST_ALIGNMENT) / BITS_PER_UNIT +@@ -8009,7 +8018,7 @@ fold_builtin_bzero (tree arglist, bool i + static tree + fold_builtin_memory_op (tree arglist, tree type, bool ignore, int endp) + { +- tree dest, src, len, destvar, srcvar, expr; ++ tree dest, src, len, destvar, srcvar, expr, inner; + unsigned HOST_WIDE_INT length; + + if (! validate_arglist (arglist, +@@ -8050,6 +8059,15 @@ fold_builtin_memory_op (tree arglist, tr + && !SCALAR_FLOAT_TYPE_P (TREE_TYPE (destvar))) + return 0; + ++ /* If destvar is a VAR_DECL or a component thereof, ++ we can use its alias set, otherwise we'd need to make ++ sure we go through alias set 0. */ ++ inner = destvar; ++ while (handled_component_p (inner)) ++ inner = TREE_OPERAND (inner, 0); ++ if (! SSA_VAR_P (inner)) ++ return 0; ++ + srcvar = src; + STRIP_NOPS (srcvar); + if (TREE_CODE (srcvar) != ADDR_EXPR) +@@ -8064,6 +8082,15 @@ fold_builtin_memory_op (tree arglist, tr + && !SCALAR_FLOAT_TYPE_P (TREE_TYPE (srcvar))) + return 0; + ++ /* If srcvar is a VAR_DECL or a component thereof, ++ we can use its alias set, otherwise we'd need to make ++ sure we go through alias set 0. */ ++ inner = srcvar; ++ while (handled_component_p (inner)) ++ inner = TREE_OPERAND (inner, 0); ++ if (! SSA_VAR_P (inner)) ++ return 0; ++ + length = tree_low_cst (len, 1); + if (GET_MODE_SIZE (TYPE_MODE (TREE_TYPE (destvar))) != length + || get_pointer_alignment (dest, BIGGEST_ALIGNMENT) / BITS_PER_UNIT diff --git a/gcc41.spec b/gcc41.spec index 5cd9fe8..06ad463 100644 --- a/gcc41.spec +++ b/gcc41.spec @@ -1,6 +1,6 @@ -%define DATE 20060926 +%define DATE 20060928 %define gcc_version 4.1.1 -%define gcc_release 26 +%define gcc_release 27 %define _unpackaged_files_terminate_build 0 %define multilib_64_archs sparc64 ppc64 s390x x86_64 %ifarch %{ix86} x86_64 ia64 @@ -132,10 +132,9 @@ Patch23: gcc41-pr28709.patch Patch24: gcc41-pr28755.patch Patch25: gcc41-pr27898.patch Patch26: gcc41-pr27567.patch -Patch27: gcc41-pr29097.patch +Patch27: gcc41-pr29272.patch Patch28: gcc41-pr29059.patch Patch29: gcc41-strncat-chk.patch -Patch30: gcc41-pr25261.patch %define _gnu %{nil} %ifarch sparc @@ -445,10 +444,9 @@ which are required to run programs compiled with the GNAT. %patch24 -p0 -b .pr28755~ %patch25 -p0 -b .pr27898~ %patch26 -p0 -b .pr27567~ -%patch27 -p0 -b .pr29097~ +%patch27 -p0 -b .pr29272~ %patch28 -p0 -b .pr29059~ %patch29 -p0 -b .strncat-chk~ -%patch30 -p0 -b .pr25261~ sed -i -e 's/4\.1\.2/4.1.1/' gcc/BASE-VER gcc/version.c sed -i -e 's/" (Red Hat[^)]*)"/" (Red Hat %{version}-%{gcc_release})"/' gcc/version.c @@ -1510,6 +1508,13 @@ fi %doc rpm.doc/changelogs/libmudflap/ChangeLog* %changelog +* Thu Sep 28 2006 Jakub Jelinek 4.1.1-27 +- update from gcc-4_1-branch (-r117225:117266) + - PR target/29230 +- restrict single entry mem{{,p}cpy,move,set} optimization to vars + and components thereof (PR middle-end/29272) +- fix java.util.Locale (Tom Tromey, #201712) + * Tue Sep 26 2006 Jakub Jelinek 4.1.1-26 - update from gcc-4_1-branch (-r117162:117225) - PRs classpath/28661, libgcj/29178, libstdc++/29179, libstdc++/29224 diff --git a/sources b/sources index 1401265..a365a84 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -691c96cd006fa802a35c63a9a7f017dd gcc-4.1.1-20060926.tar.bz2 +64e2992874d48722891f2a7ccb9cf613 gcc-4.1.1-20060928.tar.bz2