public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Earnshaw <rearnsha@arm.com>
To: Richard Guenther <richard.guenther@gmail.com>
Cc: Ulrich Weigand <uweigand@de.ibm.com>,
	 "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>,
	"ramana.radhakrishnan@linaro.org"
	<ramana.radhakrishnan@linaro.org>
Subject: Re: [RFA 4.7/4.6] Re: [PATCH v2] Target-specific limits on vector alignment
Date: Tue, 07 Aug 2012 15:09:00 -0000	[thread overview]
Message-ID: <50212F84.8080403@arm.com> (raw)
In-Reply-To: <CAFiYyc0q2+dGqDEdJ1uo4Z=Qs=kJzji_yd37cRGPngPWhZw=2Q@mail.gmail.com>

On 07/08/12 16:04, Richard Guenther wrote:
> On Tue, Aug 7, 2012 at 4:56 PM, Ulrich Weigand <uweigand@de.ibm.com> wrote:
>> Richard Guenther wrote:
>>> On Fri, Jul 27, 2012 at 5:24 PM, Ulrich Weigand <uweigand@de.ibm.com> wrote:
>>>> ChangeLog:
>>>>
>>>>         * target.def (vector_alignment): New target hook.
>>>>         * doc/tm.texi.in (TARGET_VECTOR_ALIGNMENT): Document new hook.
>>>>         * doc/tm.texi: Regenerate.
>>>>         * targhooks.c (default_vector_alignment): New function.
>>>>         * targhooks.h (default_vector_alignment): Add prototype.
>>>>         * stor-layout.c (layout_type): Use targetm.vector_alignment.
>>>>         * config/arm/arm.c (arm_vector_alignment): New function.
>>>>         (TARGET_VECTOR_ALIGNMENT): Define.
>>>>
>>>>         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Use
>>>>         vector type alignment instead of size.
>>>>         * tree-vect-loop-manip.c (vect_do_peeling_for_loop_bound): Use
>>>>         element type size directly instead of computing it from alignment.
>>>>         Fix variable naming and comment.
>>>>
>>>> testsuite/ChangeLog:
>>>>
>>>>         * lib/target-supports.exp
>>>>         (check_effective_target_vect_natural_alignment): New function.
>>>>         * gcc.dg/align-2.c: Only run on targets with natural alignment
>>>>         of vector types.
>>>>         * gcc.dg/vect/slp-25.c: Adjust tests for targets without natural
>>>>         alignment of vector types.
>>
>>
>>>> OK for mainline?
>>>
>>> Ok.
>>
>> Would it be OK to backport this to 4.7 and possibly 4.6?
>>
>> This patch represents a change in the ABI on ARM (the alignment could
>> potentially affect struct member offsets, for example), which could
>> conceivably cause incompatibilities with code compiled with older
>> versions of GCC.  We had originally decided we nevertheless want to
>> implement this change on ARM, because:
>>
>> - GCC is now in compliance with the platform ABI document
>> - the old code could actually be buggy since GCC *assumed* 16-byte
>>   alignment that wasn't actually guaranteed
>> - code actually affected by this change ought to be rare (code using
>>   NEON vector types is rare in the first place, code using *structure
>>   members* of such types is even rarer, and code using such structures
>>   in cross-module APIs seems to be extremely rare)
>>
>> Nevertheless, given we do want to make this change, it would be best
>> to roll it out as quickly as possible, to minimize the time period
>> where people might use old (not yet fixed) compilers to generate
>> non-ABI-compliant binaries.  Thus, we think it would be good for
>> the change to be applied to all still open release branches as well.
>>
>> (Note that while the patch contains changes to common code, those
>> should be no-ops for all targets that do not implement the new hook.)
> 
> I'll defer the decision to the target maintainers.  But please double-check
> for any changes in the vectorizer parts when backporting to 4.6.
> 

My inclination is to back-port this to all maintained branches (for
consistency).

However, it does need to be release-noted.

R.



  reply	other threads:[~2012-08-07 15:09 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-11 13:39 [RFC] " Richard Earnshaw
2012-06-11 14:19 ` Richard Guenther
2012-06-11 14:46   ` Richard Earnshaw
2012-06-11 14:53     ` Richard Guenther
2012-06-11 15:38       ` Richard Earnshaw
2012-06-11 18:37         ` Richard Guenther
2012-07-27 15:36           ` [PATCH v2] " Ulrich Weigand
2012-07-30  3:15             ` Hans-Peter Nilsson
2012-07-30 11:12             ` Richard Guenther
2012-07-30 14:44               ` Ulrich Weigand
2012-08-07 14:57               ` [RFA 4.7/4.6] " Ulrich Weigand
2012-08-07 15:04                 ` Richard Guenther
2012-08-07 15:09                   ` Richard Earnshaw [this message]
2012-08-07 15:15                   ` Ramana Radhakrishnan
2012-08-10 13:44                     ` [RFA wwwdocs] " Ulrich Weigand
2012-08-10 14:57                       ` Richard Earnshaw
2012-08-10 15:18                         ` Ulrich Weigand
2012-08-10 16:07                           ` Richard Earnshaw
2012-08-10 16:28                             ` Ulrich Weigand
2012-08-10 13:30                   ` [commit 4.7] " Ulrich Weigand
2012-08-10 13:31                   ` [commit 4.6] " Ulrich Weigand
2012-06-11 23:05 ` [RFC] " Hans-Peter Nilsson
2012-07-24 17:39   ` Ulrich Weigand
2012-07-26  0:10     ` Hans-Peter Nilsson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=50212F84.8080403@arm.com \
    --to=rearnsha@arm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=ramana.radhakrishnan@linaro.org \
    --cc=richard.guenther@gmail.com \
    --cc=uweigand@de.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).