This is the mail archive of the
mailing list for the GCC project.
Re: Preserve label alignment info through dbr
- From: Jeff Law <law at redhat dot com>
- To: Eric Botcazou <ebotcazou at adacore dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 17 Jul 2013 15:03:32 -0600
- Subject: Re: Preserve label alignment info through dbr
- References: <1821473 dot SyjjZnTRdx at polaris>
On 07/10/2013 03:37 AM, Eric Botcazou wrote:
I was a little surprised to find out that dbr can silently drop the alignment
information for labels computed when the CFG is valid (in compute_alignments).
The pessimization can be significant for loops when the top label needs to be
overaligned, as seen on a private port. Hence the attached patch.
Tested on SPARC/Solaris and SPARC64/Solaris, any objections?
2013-07-10 Eric Botcazou <firstname.lastname@example.org>
* rtl.h (update_alignments): Declare.
* final.c (grow_label_align): New function extracted from...
(shorten_branches): ...here. Call it.
(update_alignments): New function.
* reorg.c (sibling_labels): New variable.
(get_label_before): Add SIBLING parameter. If it is non-zero, push
the new label along with it onto the sibling_labels vector.
(fill_simple_delay_slots): Adjust call to get_label_before.
(dbr_schedule): Invoke update_alignment on the sibling_labels vector.
Looks good to me.