This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Bump alignment for small loops on PowerPC
- From: David Edelsohn <dje dot gcc at gmail dot com>
- To: Pat Haugen <pthaugen at linux dot vnet dot ibm dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Tue, 2 Nov 2010 15:18:57 -0400
- Subject: Re: [PATCH] Bump alignment for small loops on PowerPC
- References: <4CC1F004.email@example.com>
On Fri, Oct 22, 2010 at 4:11 PM, Pat Haugen <firstname.lastname@example.org> wrote:
> The following patch increases the alignment for certain small loops (5-8
> insns) on PowerPC for improved performance. Small loops can benefit by being
> contained within a single 32-byte icache sector. Spec testing was neutral,
> but it should eliminate variations in performance I have seen in the past
> due to whether one of these loops crossed a 32-byte boundary.
> Bootstrap/regtested on powerpc64-linux with no new regressions. ?OK for
> 2010-10-22 ?Pat Haugen <email@example.com>
> ? ?* final.c (compute_alignments): Compute/free loop info all the time.
> ? ?* config/rs6000/rs6000.h (LOOP_ALIGN): Define.
> ? ?* config/rs6000/rs6000-protos.h (rs6000_loop_align): Declare.
> ? ?* config/rs6000/t-rs6000 (rs6000.o): Add cfgloop.h.
> ? ?* config/rs6000/rs6000.c (cfgloop.h): Include.
> ? ?(can_override_loop_align): New.
> ? ?(rs6000_option_override_internal): Set it.
> ? ?(TARGET_ASM_LOOP_ALIGN_MAX_SKIP): Define target hook.
> ? ?(rs6000_loop_align): New function.
> ? ?(rs6000_loop_align_max_skip): Likewise.
> ? ?* testsuite/gcc.target/powerpc/loop_align.c: New.
The rs6000 parts are okay; I do not have the authority to approve the
As Eric mentioned, please note the separate file for testsuite ChangeLog.