This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, PR target/65103, 2/3] Propagate address constants into loops for i386
- From: Richard Sandiford <rdsandiford at googlemail dot com>
- To: Ilya Enkovich <enkovich dot gnu at gmail dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sun, 15 Mar 2015 20:30:17 +0000
- Subject: Re: [PATCH, PR target/65103, 2/3] Propagate address constants into loops for i386
- Authentication-results: sourceware.org; auth=none
- References: <20150310150027 dot GC27860 at msticlxl57 dot ims dot intel dot com>
Ilya Enkovich <enkovich.gnu@gmail.com> writes:
> This patch allows propagation of loop invariants for i386 if propagated
> value is a constant to be used in address operand. Bootstrapped and
> tested on x86_64-unknown-linux-gnu. OK for trunk or stage 1?
Is it necessary for this to be a target hook? The concept doesn't seem
particularly target-specific. We should only propagate into the address
if the new cost is no greater than the old cost, but if the address
meets that condition and if propagating at this point in the pipeline is
a win on x86, then wouldn't it be a win for other targets too?
Thanks,
Richard