re PR rtl-optimization/48156 (wrong code with -fcrossjumping)
PR rtl-optimization/48156 * df-core.c (df_get_bb_dirty): Use df_lr if df_live is NULL, assume df and df_lr are not NULL. * gcc.dg/pr48156.c: New test. From-SVN: r171195
This commit is contained in:
parent
b6a75dda1d
commit
65e0a0f3c8
@ -1,3 +1,9 @@
|
|||||||
|
2011-03-20 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/48156
|
||||||
|
* df-core.c (df_get_bb_dirty): Use df_lr if df_live is NULL,
|
||||||
|
assume df and df_lr are not NULL.
|
||||||
|
|
||||||
2011-03-20 Ramana Radhakrishnan <ramana.radhakrishnan@linaro.org>
|
2011-03-20 Ramana Radhakrishnan <ramana.radhakrishnan@linaro.org>
|
||||||
|
|
||||||
PR debug/48023
|
PR debug/48023
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* Allocation for dataflow support routines.
|
/* Allocation for dataflow support routines.
|
||||||
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
|
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
|
||||||
2008, 2009, 2010 Free Software Foundation, Inc.
|
2008, 2009, 2010, 2011 Free Software Foundation, Inc.
|
||||||
Originally contributed by Michael P. Hayes
|
Originally contributed by Michael P. Hayes
|
||||||
(m.hayes@elec.canterbury.ac.nz, mhayes@redhat.com)
|
(m.hayes@elec.canterbury.ac.nz, mhayes@redhat.com)
|
||||||
Major rewrite contributed by Danny Berlin (dberlin@dberlin.org)
|
Major rewrite contributed by Danny Berlin (dberlin@dberlin.org)
|
||||||
@ -1400,10 +1400,9 @@ df_mark_solutions_dirty (void)
|
|||||||
bool
|
bool
|
||||||
df_get_bb_dirty (basic_block bb)
|
df_get_bb_dirty (basic_block bb)
|
||||||
{
|
{
|
||||||
if (df && df_live)
|
return bitmap_bit_p ((df_live
|
||||||
return bitmap_bit_p (df_live->out_of_date_transfer_functions, bb->index);
|
? df_live : df_lr)->out_of_date_transfer_functions,
|
||||||
else
|
bb->index);
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2011-03-20 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/48156
|
||||||
|
* gcc.dg/pr48156.c: New test.
|
||||||
|
|
||||||
2011-03-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
|
2011-03-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
|
||||||
|
|
||||||
PR libfortran/47439
|
PR libfortran/47439
|
||||||
|
45
gcc/testsuite/gcc.dg/pr48156.c
Normal file
45
gcc/testsuite/gcc.dg/pr48156.c
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
/* PR rtl-optimization/48156 */
|
||||||
|
/* { dg-do run } */
|
||||||
|
/* { dg-options "-O -fcrossjumping --param min-crossjump-insns=1" } */
|
||||||
|
|
||||||
|
extern void abort (void);
|
||||||
|
|
||||||
|
static int __attribute__ ((noinline, noclone))
|
||||||
|
equals (int s1, int s2)
|
||||||
|
{
|
||||||
|
return s1 == s2;
|
||||||
|
}
|
||||||
|
|
||||||
|
static int __attribute__ ((noinline, noclone))
|
||||||
|
bar (void)
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void __attribute__ ((noinline, noclone))
|
||||||
|
baz (int f, int j)
|
||||||
|
{
|
||||||
|
if (f != 4 || j != 2)
|
||||||
|
abort ();
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
foo (int x)
|
||||||
|
{
|
||||||
|
int i = 0, j = bar ();
|
||||||
|
|
||||||
|
if (x == 1)
|
||||||
|
i = 2;
|
||||||
|
|
||||||
|
if (j && equals (i, j))
|
||||||
|
baz (8, i);
|
||||||
|
else
|
||||||
|
baz (4, i);
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
foo (1);
|
||||||
|
return 0;
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user