backport: re PR rtl-optimization/48141 (DSE compile time hog)
Backported from mainline 2011-03-17 Jakub Jelinek <jakub@redhat.com> PR rtl-optimization/48141 * dse.c (record_store): If no positions are needed in an insn that cannot be deleted, at least unchain it from active_local_stores. * gcc.dg/pr48141.c: New test. From-SVN: r172132
This commit is contained in:
parent
438d2301ba
commit
c404d187c8
|
@ -1,3 +1,12 @@
|
|||
2011-04-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2011-03-17 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/48141
|
||||
* dse.c (record_store): If no positions are needed in an insn
|
||||
that cannot be deleted, at least unchain it from active_local_stores.
|
||||
|
||||
2011-04-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR tree-optimization/46491
|
||||
|
|
|
@ -1588,8 +1588,7 @@ record_store (rtx body, bb_info_t bb_info)
|
|||
|
||||
/* An insn can be deleted if every position of every one of
|
||||
its s_infos is zero. */
|
||||
if (any_positions_needed_p (s_info)
|
||||
|| ptr->cannot_delete)
|
||||
if (any_positions_needed_p (s_info))
|
||||
del = false;
|
||||
|
||||
if (del)
|
||||
|
@ -1600,8 +1599,9 @@ record_store (rtx body, bb_info_t bb_info)
|
|||
last->next_local_store = ptr->next_local_store;
|
||||
else
|
||||
active_local_stores = ptr->next_local_store;
|
||||
|
||||
delete_dead_store_insn (insn_to_delete);
|
||||
|
||||
if (!insn_to_delete->cannot_delete)
|
||||
delete_dead_store_insn (insn_to_delete);
|
||||
}
|
||||
else
|
||||
last = ptr;
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
2011-04-07 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2011-03-17 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/48141
|
||||
* gcc.dg/pr48141.c: New test.
|
||||
|
||||
2010-11-15 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR tree-optimization/46491
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
/* PR rtl-optimization/48141 */
|
||||
/* { dg-do compile } */
|
||||
/* { dg-options "-O -fno-tree-fre" } */
|
||||
|
||||
#define A i = 0;
|
||||
#define B A A A A A A A A A A
|
||||
#define C B B B B B B B B B B
|
||||
#define D C C C C C C C C C C
|
||||
#define E D D D D D D D D D D
|
||||
|
||||
int
|
||||
foo (void)
|
||||
{
|
||||
volatile int i = 0;
|
||||
E E E E E E E E E E E
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue