Index: libgomp/configure.tgt =================================================================== --- libgomp/configure.tgt (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libgomp/configure.tgt (.../branches/gcc-4_5-branch) (wersja 168030) @@ -125,6 +125,10 @@ config_path="bsd posix" ;; + mips-sgi-irix6*) + # Need to link with -lpthread so libgomp.so is self-contained. + XLDFLAGS="${XLDFLAGS} -lpthread" + ;; *) ;; Index: libgomp/ChangeLog =================================================================== --- libgomp/ChangeLog (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libgomp/ChangeLog (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1,3 +1,10 @@ +2010-12-17 Rainer Orth + + Backport from mainline: + 2010-12-01 Rainer Orth + + * configure.tgt (mips-sgi-irix6*): Add -lpthread to XLDFLAGS. + 2010-12-16 Release Manager * GCC 4.5.2 released. Index: gcc/DATESTAMP =================================================================== --- gcc/DATESTAMP (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/DATESTAMP (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1 +1 @@ -20101216 +20101218 Index: gcc/DEV-PHASE =================================================================== --- gcc/DEV-PHASE (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/DEV-PHASE (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1 @@ +prerelease Index: gcc/tree-ssa-sccvn.c =================================================================== --- gcc/tree-ssa-sccvn.c (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/tree-ssa-sccvn.c (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1063,6 +1063,7 @@ size2 = TREE_INT_CST_LOW (gimple_call_arg (def_stmt, 2)) * 8; if ((unsigned HOST_WIDE_INT)size2 / 8 == TREE_INT_CST_LOW (gimple_call_arg (def_stmt, 2)) + && maxsize2 != -1 && operand_equal_p (base, base2, 0) && offset2 <= offset && offset2 + size2 >= offset + maxsize) @@ -1086,7 +1087,8 @@ HOST_WIDE_INT offset2, size2, maxsize2; base2 = get_ref_base_and_extent (gimple_assign_lhs (def_stmt), &offset2, &size2, &maxsize2); - if (operand_equal_p (base, base2, 0) + if (maxsize2 != -1 + && operand_equal_p (base, base2, 0) && offset2 <= offset && offset2 + size2 >= offset + maxsize) { @@ -1116,7 +1118,8 @@ /* See if the assignment kills REF. */ base2 = get_ref_base_and_extent (gimple_assign_lhs (def_stmt), &offset2, &size2, &maxsize2); - if (!operand_equal_p (base, base2, 0) + if (maxsize2 == -1 + || !operand_equal_p (base, base2, 0) || offset2 > offset || offset2 + size2 < offset + maxsize) return (void *)-1; Index: gcc/ChangeLog =================================================================== --- gcc/ChangeLog (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/ChangeLog (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1,3 +1,23 @@ +2010-12-18 Alexandre Oliva + + PR debug/46756 + * jump.c (mark_all_labels): Skip debug insns. + +2010-12-18 Alexandre Oliva + + PR debug/46782 + * cfgcleanup.c (try_forward_edges): Skip debug insns. + +2010-12-16 Eric Botcazou + + * tree-ssa-sccvn.c (vn_reference_lookup_3): Always punt if the call to + get_ref_base_and_extent returns -1 as the max size. + +2010-12-16 Richard Guenther + + * DEV-PHASE: Set back to prerelease. + * BASE-VER: Bump to 4.5.3. + 2010-12-16 Release Manager * GCC 4.5.2 released. Index: gcc/testsuite/gnat.dg/opt13.adb =================================================================== --- gcc/testsuite/gnat.dg/opt13.adb (.../tags/gcc_4_5_2_release) (wersja 0) +++ gcc/testsuite/gnat.dg/opt13.adb (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1,13 @@ +-- { dg-do run } +-- { dg-options "-O" } + +with Opt13_Pkg; use Opt13_Pkg; + +procedure Opt13 is + T : My_Type; +begin + Allocate (T); + if N /= 1 then + raise Program_Error; + end if; +end; Index: gcc/testsuite/gnat.dg/opt13_pkg.adb =================================================================== --- gcc/testsuite/gnat.dg/opt13_pkg.adb (.../tags/gcc_4_5_2_release) (wersja 0) +++ gcc/testsuite/gnat.dg/opt13_pkg.adb (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1,31 @@ +package body Opt13_Pkg is + + subtype Index_Type is Natural range 0 .. 16; + + type Arr is array (Index_Type range <>) of Integer; + + type Rec is record + F1, F2, F3 : Float; + N : Natural; + B1, B2 : Boolean; + F4 : Float; + end record; + + type Data (D : Index_Type) is record + A : Arr (1 .. D); + R : Rec; + end record; + + Zero : constant Rec := (0.0, 0.0, 0.0, 0, False, False, 0.0); + + procedure Allocate (T : out My_Type) is + begin + T := new Data (Index_Type'last); + T.R := Zero; + + for I in 1 .. T.A'last loop + N := 1; + end loop; + end; + +end Opt13_Pkg; Index: gcc/testsuite/gnat.dg/opt13_pkg.ads =================================================================== --- gcc/testsuite/gnat.dg/opt13_pkg.ads (.../tags/gcc_4_5_2_release) (wersja 0) +++ gcc/testsuite/gnat.dg/opt13_pkg.ads (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1,15 @@ +package Opt13_Pkg is + + N : Natural := 0; + + type My_Type is private; + + procedure Allocate (T : out My_Type); + +private + + type Data; + + type My_Type is access Data; + +end Opt13_Pkg; Index: gcc/testsuite/gcc.dg/debug/pr46782.c =================================================================== --- gcc/testsuite/gcc.dg/debug/pr46782.c (.../tags/gcc_4_5_2_release) (wersja 0) +++ gcc/testsuite/gcc.dg/debug/pr46782.c (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1,11 @@ +/* PR debug/46782 */ +/* { dg-do compile } */ +/* { dg-options "-w -O0 -fvar-tracking -fcompare-debug" } */ + +void foo (int i) +{ + if (i) + i++; + while (i) + ; +} Index: gcc/testsuite/ChangeLog =================================================================== --- gcc/testsuite/ChangeLog (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/testsuite/ChangeLog (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1,3 +1,23 @@ +2010-12-18 Alexandre Oliva + + PR debug/46756 + * gfortran.dg/debug/pr46756.f: New. + +2010-12-18 Alexandre Oliva + + PR debug/46782 + * gcc.dg/debug/pr46782.c: New. + +2010-12-17 Daniel Kraft + + PR fortran/46794 + * gfortran.dg/power2.f90: Initialize variables. + +2010-12-16 Eric Botcazou + + * gnat.dg/opt13.adb: New test. + * gnat.dg/opt13_pkg.ad[sb]: New helper. + 2010-12-16 Release Manager * GCC 4.5.2 released. Index: gcc/testsuite/gfortran.dg/debug/pr46756.f =================================================================== --- gcc/testsuite/gfortran.dg/debug/pr46756.f (.../tags/gcc_4_5_2_release) (wersja 0) +++ gcc/testsuite/gfortran.dg/debug/pr46756.f (.../branches/gcc-4_5-branch) (wersja 168030) @@ -0,0 +1,29 @@ +C PR debug/46756, reduced from ../20010519-1.f +C { dg-do compile } +C { dg-options "-O -fcompare-debug" } + LOGICAL QDISK,QDW,QCMPCT + LOGICAL LNOMA,LRAISE,LSCI,LBIG + ASSIGN 801 TO I800 ! { dg-warning "Deleted feature: ASSIGN" "Deleted feature: ASSIGN" } + GOTO 800 + 801 CONTINUE + ASSIGN 761 TO I760 ! { dg-warning "Deleted feature: ASSIGN" "Deleted feature: ASSIGN" } + 761 CONTINUE + IF(LSCI) THEN + DO I=1,LENCM + ENDDO + ENDIF + DO WHILE((CVGMX.GT.TOLDIM).AND.(ITER.LT.ITMX)) + IF(.NOT.QDW) THEN + ASSIGN 641 to I640 ! { dg-warning "Deleted feature: ASSIGN" "Deleted feature: ASSIGN" } + GOTO 640 + 641 CONTINUE + ENDIF + ENDDO + GOTO 700 + 640 CONTINUE + GOTO I640 ! { dg-warning "Deleted feature: Assigned" "Assigned GO TO" } + 700 CONTINUE + GOTO I760 ! { dg-warning "Deleted feature: Assigned" "Assigned GO TO" } + 800 CONTINUE + GOTO I800 ! { dg-warning "Deleted feature: Assigned" "Assigned GO TO" } + END Index: gcc/testsuite/gfortran.dg/power2.f90 =================================================================== --- gcc/testsuite/gfortran.dg/power2.f90 (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/testsuite/gfortran.dg/power2.f90 (.../branches/gcc-4_5-branch) (wersja 168030) @@ -13,6 +13,9 @@ INTEGER(KIND=1) :: k1 INTEGER(KIND=2) :: k2 + k1 = 1_1 + k2 = 1_2 + k1 = 1_1 + 1_1**k1 k2 = 1_2 + 1_2**k2 Index: gcc/jump.c =================================================================== --- gcc/jump.c (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/jump.c (.../branches/gcc-4_5-branch) (wersja 168030) @@ -194,7 +194,7 @@ rtx prev_nonjump_insn = NULL; for (insn = f; insn; insn = NEXT_INSN (insn)) - if (INSN_P (insn)) + if (NONDEBUG_INSN_P (insn)) { mark_jump_label (PATTERN (insn), insn, 0); Index: gcc/BASE-VER =================================================================== --- gcc/BASE-VER (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/BASE-VER (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1 +1 @@ -4.5.2 +4.5.3 Index: gcc/cfgcleanup.c =================================================================== --- gcc/cfgcleanup.c (.../tags/gcc_4_5_2_release) (wersja 168030) +++ gcc/cfgcleanup.c (.../branches/gcc-4_5-branch) (wersja 168030) @@ -482,15 +482,20 @@ /* When not optimizing, ensure that edges or forwarder blocks with different locus are not optimized out. */ int locus = single_succ_edge (target)->goto_locus; + rtx last ; if (locus && goto_locus && !locator_eq (locus, goto_locus)) counter = n_basic_blocks; else if (locus) goto_locus = locus; - if (INSN_P (BB_END (target))) + last = BB_END (target); + if (DEBUG_INSN_P (last)) + last = prev_nondebug_insn (last); + + if (last && INSN_P (last)) { - locus = INSN_LOCATOR (BB_END (target)); + locus = INSN_LOCATOR (last); if (locus && goto_locus && !locator_eq (locus, goto_locus)) Index: libstdc++-v3/ChangeLog =================================================================== --- libstdc++-v3/ChangeLog (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libstdc++-v3/ChangeLog (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1,3 +1,11 @@ +2010-12-17 Rainer Orth + + Backport from mainline: + 2010-12-10 Rainer Orth + + * testsuite/lib/libstdc++.exp (v3-build_support): Delete + libtestc++.a before creation. + 2010-12-16 Release Manager * GCC 4.5.2 released. Index: libstdc++-v3/testsuite/lib/libstdc++.exp =================================================================== --- libstdc++-v3/testsuite/lib/libstdc++.exp (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libstdc++-v3/testsuite/lib/libstdc++.exp (.../branches/gcc-4_5-branch) (wersja 168030) @@ -586,6 +586,15 @@ } # Collect into libtestc++.a + # Delete libtestc++.a first. Mixed 32 and 64-bit archives cannot be + # linked on IRIX 6. + # Use same procedure as gcc-dg.exp (remove-build-file). + if [is_remote host] { + # Ensure the host knows the file is gone by deleting there + # first. + remote_file host delete "./libtestc++.a" + } + remote_file build delete "./libtestc++.a" if [info exists env(AR)] { set ar $env(AR) } else { Index: libffi/ChangeLog =================================================================== --- libffi/ChangeLog (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libffi/ChangeLog (.../branches/gcc-4_5-branch) (wersja 168030) @@ -1,3 +1,11 @@ +2010-12-17 Rainer Orth + + Backport from mainline: + 2010-12-01 Rainer Orth + + * testsuite/libffi.call/ffitest.h [__sgi] (PRId64, PRIu64): Define. + (PRIuPTR): Define. + 2010-12-16 Release Manager * GCC 4.5.2 released. Index: libffi/testsuite/libffi.call/ffitest.h =================================================================== --- libffi/testsuite/libffi.call/ffitest.h (.../tags/gcc_4_5_2_release) (wersja 168030) +++ libffi/testsuite/libffi.call/ffitest.h (.../branches/gcc-4_5-branch) (wersja 168030) @@ -77,6 +77,26 @@ #define PRIuPTR "lu" #endif +/* IRIX kludge. */ +#if defined(__sgi) +/* IRIX 6.5 provides all definitions, but only for C99 + compilations. */ +#if (_MIPS_SZLONG == 32) +#define PRId64 "lld" +#define PRIu64 "llu" +#endif +/* This doesn't match , which always has "lld" here, but the + arguments are uint64_t, int64_t, which are unsigned long, long for + 64-bit in . */ +#if (_MIPS_SZLONG == 64) +#define PRId64 "ld" +#define PRIu64 "lu" +#endif +/* This doesn't match , which has "u" here, but the arguments + are uintptr_t, which is always unsigned long. */ +#define PRIuPTR "lu" +#endif + /* Solaris < 10 kludge. */ #if defined(__sun__) && defined(__svr4__) && !defined(PRIuPTR) #if defined(__arch64__) || defined (__x86_64__)