Backport PRs 42166, 42215, 42234, 42269, 42299

Backport testcases from trunk.

2009-12-11  H.J. Lu  <hongjiu.lu@intel.com>

	Backport from mainline:
	2009-12-07  Richard Henderson  <rth@redhat.com>

	PR rtl-opt/42269
	* gcc.c-torture/execute/pr42269-2.c: New.

	2009-12-07  Richard Henderson  <rth@redhat.com>

	PR debug/42299
	PR debug/42166
	* gcc.c-torture/compile/pr42299.c: New.
	* gfortran.dg/pr42166.f90: Likewise.

	2009-12-06  Richard Henderson  <rth@redhat.com>

	PR debug/42234
	* gcc.c-torture/compile/pr42234.c: New.

	2009-12-02  Richard Henderson  <rth@redhat.com>

	PR tree-opt/42215
	* gcc.dg/pr42215.c: New.

From-SVN: r155191
This commit is contained in:
H.J. Lu 2009-12-12 01:45:12 +00:00 committed by H.J. Lu
parent ea50055503
commit 0ce1262438
6 changed files with 110 additions and 0 deletions

View File

@ -1,3 +1,28 @@
2009-12-11 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline:
2009-12-07 Richard Henderson <rth@redhat.com>
PR rtl-opt/42269
* gcc.c-torture/execute/pr42269-2.c: New.
2009-12-07 Richard Henderson <rth@redhat.com>
PR debug/42299
PR debug/42166
* gcc.c-torture/compile/pr42299.c: New.
* gfortran.dg/pr42166.f90: Likewise.
2009-12-06 Richard Henderson <rth@redhat.com>
PR debug/42234
* gcc.c-torture/compile/pr42234.c: New.
2009-12-02 Richard Henderson <rth@redhat.com>
PR tree-opt/42215
* gcc.dg/pr42215.c: New.
2009-12-11 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline:

View File

@ -0,0 +1,14 @@
/* { dg-options "-g" } */
void
foo (int x)
{
struct S { int s; } d = { 1 };
unsigned int e = 1;
if (x)
e = x && d.s;
else
for (e = 0; e <= 3; e--)
;
e++;
}

View File

@ -0,0 +1,23 @@
/* { dg-options "-g" } */
static int
foo (int x, int y)
{
if (y)
goto lab;
if (x)
y = 0;
if (y)
goto lab;
y = 0;
lab:
return y;
}
void
baz (int x, int y)
{
y = foo (x, y);
if (y != 0)
bar ();
}

View File

@ -0,0 +1,15 @@
/* Make sure that language + abi extensions in passing S interoperate. */
static long long __attribute__((noinline))
foo (unsigned short s)
{
return (short) s;
}
unsigned short s = 0xFFFF;
int
main (void)
{
return foo (s) + 1 != 0;
}

View File

@ -0,0 +1,13 @@
/* { dg-do compile } */
/* { dg-options "-O2 -ftree-loop-distribution" } */
extern int A[];
extern int B[];
void f(int i)
{
while (i-- > 0) {
A[i] = 0;
B[i] = 0;
}
}

View File

@ -0,0 +1,20 @@
! { dg-options "-O2 -g" }
MODULE powell
INTEGER, PARAMETER :: dp=8
CONTAINS
SUBROUTINE newuob (n, bmat, ndim, d, vlag, w, npt)
REAL(dp), DIMENSION(ndim, *), INTENT(inout) :: bmat
REAL(dp), DIMENSION(*), INTENT(inout) :: d, vlag, w
REAL(dp) :: sum
INTEGER, INTENT(in) :: npt
DO j=1,n
jp=npt+j
DO k=1,n
sum=sum+bmat(jp,k)*d(k)
END DO
vlag(jp)=sum
END DO
END SUBROUTINE newuob
END MODULE powell