https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102793

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Richard Biener from comment #3)
> I wonder why tail-merging doesn't do it's job here.  It does (on
> x86_64-linux):

Oh I missed that.

> but what's missing is possibly some if-combine?

Yes because ifcombine happens way way too early. I wonder if we should not have
another one or move the currently one to be after the loop optimizations are
done.

> IMHO ccmp expansion should be re-written to a pre RTL expansion GIMPLE
> transform.

basically ccmp expension is just ifcombine really.
That is:
cc = bar cmp 0
cc = cc.eq ? ne : d1 cmp d2
cset cc.ne
So this is why doing a late pass ifcombine might be good for aarch64; I don't
know if how much compile time it would cost though.

Reply via email to