This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: IRA improvements 4/4


Nathan Froyd wrote:
On Wed, Jul 07, 2010 at 09:31:47AM -0400, Vladimir Makarov wrote:
This is the last patch to speed up IRA. The big part of the patch
decreases allocno structure footprint (more than 2 times) improving
data locality. The patch also contains manual optimizations of some
critical loops.

I am underqualified to comment on the majority of the patch, but this pattern:

@@ -2425,7 +2411,7 @@ copy_info_to_removed_store_destinations a != NULL;
a = ALLOCNO_NEXT_REGNO_ALLOCNO (a))
{
- if (a != regno_top_level_allocno_map[REGNO (ALLOCNO_REG (a))])
+ if (a != regno_top_level_allocno_map[REGNO (ALLOCNO_EMIT_DATA (a)->reg)])

with REGNO (ALLOCNO_EMIT_DATA (a)->reg) is reasonably common. (fgrep says 28 occurrences.) Is it reasonable to factor this out into:

static <mumble>
regno_for_emit_data (<mumble> a)
{
  return REGNO (ALLOCNO_EMIT_DATA (a)->reg);
}

WDYT?
Yes, that is better. Thanks for pointing this. I'll modify the patch.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]