patches/gcc/3.3.3/pr11587-1-test.patch
changeset 1 eeea35fbf182
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/patches/gcc/3.3.3/pr11587-1-test.patch	Sat Feb 24 11:00:05 2007 +0000
     1.3 @@ -0,0 +1,39 @@
     1.4 +--- /dev/null	Sat Dec 14 13:56:51 2002
     1.5 ++++ gcc-3.3.1/gcc/testsuite/gcc.dg/pr11587-1.c	Mon Sep 15 08:46:00 2003
     1.6 +@@ -0,0 +1,36 @@
     1.7 ++/* PR optimization/11587
     1.8 ++ * Reporter: Michael Eager <eager@mvista.com>
     1.9 ++ * Summary: [3.3/3.4 Regression] SH ICE in reload_cse_simplify_operand, postreload.c
    1.10 ++ * Keywords: ice-on-valid-code
    1.11 ++ *
    1.12 ++ * Note: a fix exists; see bugzilla
    1.13 ++ *
    1.14 ++ * Testcase tweaked by dank@kegel.com
    1.15 ++ * Not marked as xfail since it's a regression.
    1.16 ++ */
    1.17 ++
    1.18 ++/* { dg-do compile } */
    1.19 ++/* { dg-options "-O1" } */
    1.20 ++int foo1(void);
    1.21 ++int foo2();
    1.22 ++int foo3();
    1.23 ++
    1.24 ++static int goo()
    1.25 ++{
    1.26 ++	int i;
    1.27 ++
    1.28 ++	if (i <= 0)
    1.29 ++		return i;
    1.30 ++
    1.31 ++	if (foo1() > 1) {
    1.32 ++		i = foo2();
    1.33 ++		if (i < 0)
    1.34 ++			return i;
    1.35 ++		if (i) {
    1.36 ++			if (foo3())
    1.37 ++				return 1;
    1.38 ++			return 0;
    1.39 ++		}
    1.40 ++	}
    1.41 ++
    1.42 ++}