* [ira] small fix for save/restore placement optimization
@ 2008-06-26 20:58 Vladimir Makarov
0 siblings, 0 replies; only message in thread
From: Vladimir Makarov @ 2008-06-26 20:58 UTC (permalink / raw)
To: gcc-patches
The following patch fixes a problem in save/restore optimization which I
found on power6.
2008-06-26 Vladimir Makarov <vmakarov@redhat.com>
* caller-save.c (make_global_save_analysis): Add entry and exit
blocks to all_blocks.
(save_call_clobbered_regs): Initialize bb_info for entry/exit
blocks.
Index: caller-save.c
===================================================================
--- caller-save.c (revision 137155)
+++ caller-save.c (working copy)
@@ -1548,7 +1548,7 @@ make_global_save_analysis (void)
int iter, changed_p;
all_blocks = BITMAP_ALLOC (NULL);
- FOR_EACH_BB (bb)
+ FOR_ALL_BB (bb)
{
bitmap_set_bit (all_blocks, bb->index);
}
@@ -1734,6 +1734,8 @@ save_call_clobbered_regs (void)
loop->aux = xmalloc (sizeof (struct loop_info));
CLEAR_HARD_REG_SET (LOOP_INFO (loop)->mentioned_regs);
}
+ memset (BB_INFO (ENTRY_BLOCK_PTR), 0, sizeof (struct bb_info));
+ memset (BB_INFO (EXIT_BLOCK_PTR), 0, sizeof (struct bb_info));
make_global_save_analysis ();
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-06-26 20:58 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-26 20:58 [ira] small fix for save/restore placement optimization Vladimir Makarov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).