re PR rtl-optimization/61278 (ICE with LTO (lto-wrapper failed) on x86_64-linux-gnu in 64-bit mode)
ChangeLog: 2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org> PR rtl-optimization/61278 * shrink-wrap.c (move_insn_for_shrink_wrap): Check df_live. testsuite/ChangeLog: 2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org> * gcc.dg/lto/pr61278_0.c: New test. * gcc.dg/lto/pr61278_1.c: New test. From-SVN: r210922
This commit is contained in:
parent
88f32f0f92
commit
d29d688acb
@ -1,4 +1,8 @@
|
||||
ChangeLog:
|
||||
2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org>
|
||||
|
||||
PR rtl-optimization/61278
|
||||
* shrink-wrap.c (move_insn_for_shrink_wrap): Check df_live.
|
||||
|
||||
2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org>
|
||||
|
||||
PR rtl-optimization/61220
|
||||
|
@ -213,8 +213,15 @@ move_insn_for_shrink_wrap (basic_block bb, rtx insn,
|
||||
if (EDGE_COUNT (bb->succs) == 1)
|
||||
return false;
|
||||
|
||||
/* If DF_LIVE doesn't exist, i.e. at -O1, just give up. */
|
||||
if (!df_live)
|
||||
return false;
|
||||
|
||||
next_block = split_edge (live_edge);
|
||||
|
||||
/* We create a new basic block. Call df_grow_bb_info to make sure
|
||||
all data structures are allocated. */
|
||||
df_grow_bb_info (df_live);
|
||||
bitmap_copy (df_get_live_in (next_block), df_get_live_out (bb));
|
||||
df_set_bb_dirty (next_block);
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org>
|
||||
|
||||
* gcc.dg/lto/pr61278_0.c: New test.
|
||||
* gcc.dg/lto/pr61278_1.c: New test.
|
||||
|
||||
2014-05-26 Zhenqiang Chen <zhenqiang.chen@linaro.org>
|
||||
|
||||
* gcc.dg/pr61220.c: New test.
|
||||
|
30
gcc/testsuite/gcc.dg/lto/pr61278_0.c
Normal file
30
gcc/testsuite/gcc.dg/lto/pr61278_0.c
Normal file
@ -0,0 +1,30 @@
|
||||
/* { dg-lto-do link } */
|
||||
/* { dg-lto-options { { -flto -O0 } } } */
|
||||
/* { dg-extra-ld-options " -flto -O1 " } */
|
||||
|
||||
static unsigned int
|
||||
fn1 (int p1, int p2)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
char a, b, c;
|
||||
|
||||
char
|
||||
foo (char *p)
|
||||
{
|
||||
int i;
|
||||
for (b = 1 ; b > 0; b++)
|
||||
{
|
||||
for (i = 0; i < 2; i++)
|
||||
;
|
||||
for (a = 1; a > 0; a++)
|
||||
{
|
||||
char d[1] = { 0 };
|
||||
if (*p)
|
||||
break;
|
||||
c ^= fn1 (fn1 (fn1 (0, 0), 0), 0);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
13
gcc/testsuite/gcc.dg/lto/pr61278_1.c
Normal file
13
gcc/testsuite/gcc.dg/lto/pr61278_1.c
Normal file
@ -0,0 +1,13 @@
|
||||
/* { dg-lto-do link } */
|
||||
/* { dg-lto-options { { -flto -O1 } } } */
|
||||
|
||||
extern char foo (char *);
|
||||
|
||||
char d;
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
foo (&d);
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user