This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Small reg-stack improvement (PR target/70465)
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Uros Bizjak <ubizjak at gmail dot com>, Jeff Law <law at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 22 Feb 2017 00:51:25 +0100
- Subject: Re: [PATCH] Small reg-stack improvement (PR target/70465)
- Authentication-results: sourceware.org; auth=none
- References: <20170221212347.GY1849@tucnak>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Tue, Feb 21, 2017 at 10:23:47PM +0100, Jakub Jelinek wrote:
> As reported by Uros, the
> fld a
> fld b
> fxchg %st(1)
> optimization to
> fld b
> fld a
> misses several important cases, one is FLOAT_EXTEND memory loads where
> the memory is SFmode or DFmode but we extend it to a wider mode, and
> the other is when we load a known i?87 constant like 0.0, 1.0, PI etc.
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
I've done another pair of bootstraps/regtests to gather statistics on how often
does this patch swap fld* that had fxch %st(1) after it instead, and
in both it triggered 9858 times.
So it is less often than the first PR70465 patch (which triggered
26783 times), but still significant.
Jakub