http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58041

--- Comment #19 from Martin Jambor <jamborm at gcc dot gnu.org> ---
(In reply to Bill Schmidt from comment #15)
> Bernd, Mikael, Martin:  Could you please test this on your respective
> targets?

Well, "my target" is x86_64 but yes, it works.  

(In reply to Bill Schmidt from comment #11)
> Hi Martin,
> 
> Your assumptions are correct, but I'm not sure this is the best place to
> handle it.  It looks like what you are doing is replacing one already
> correct memory reference with another, both of which will generate somewhat
> nasty code.  Therefore there isn't much reason to do the transformation at
> all in the first place.  I think I would rather analyze the reference when
> considering adding the reference to the candidate table, and leaving it out
> of consideration altogether.  What do you think?

I don't know, at least in theory the optimization might help somewhat
anyway, especially on targets that can handle misalignment memory
accesses.  But you are right that generally misaligned access will be
slow either way.

Anyway, I don't really care, I assume you contributed the code so you
are more qualified to make a judgment and if you prefer one way over
the other, go for it.

I'll leave it to you and won't submit any patch then.  Please make
sure that the two testcases are added to the testsuite before you
close the bug.  The x86_64-linux tetcase from comment #10 is generic
enough that it can go to gcc.dg/torture/, the original ARM one needs
to go to some arm-specific place.

Reply via email to