This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: Optimize ix86_reorg
- From: Richard Guenther <richard dot guenther at gmail dot com>
- To: "H.J. Lu" <hjl dot tools at gmail dot com>
- Cc: gcc-patches at gcc dot gnu dot org, ubizjak at gmail dot com
- Date: Fri, 15 May 2009 18:51:18 +0200
- Subject: Re: PATCH: Optimize ix86_reorg
- References: <20090515164730.GA22599@lucon.org>
On Fri, May 15, 2009 at 6:47 PM, H.J. Lu <hongjiu.lu@intel.com> wrote:
> Hi,
>
> ix86_reorg may call optimize_function_for_speed_p twice. This patch
> removes the second call. ?OK for trunk?
Ok.
Richard.
> Thanks.
>
>
> H.J.
> ---
> 2009-05-14 ?H.J. Lu ?<hongjiu.lu@intel.com>
>
> ? ? ? ?* config/i386.c (ix86_reorg): Call optimize_function_for_speed_p
> ? ? ? ?only once.
>
> --- i386.c ? ? ?2009-05-15 02:40:04.000000000 -0700
> +++ i386.c ? ? ?2009-05-15 09:33:01.000000000 -0700
> @@ -27359,12 +27359,13 @@ ix86_pad_returns (void)
> ?static void
> ?ix86_reorg (void)
> ?{
> - ?if (TARGET_PAD_RETURNS && optimize
> - ? ? ?&& optimize_function_for_speed_p (cfun))
> - ? ?ix86_pad_returns ();
> - ?if (TARGET_FOUR_JUMP_LIMIT && optimize
> - ? ? ?&& optimize_function_for_speed_p (cfun))
> - ? ?ix86_avoid_jump_misspredicts ();
> + ?if (optimize && optimize_function_for_speed_p (cfun))
> + ? ?{
> + ? ? ?if (TARGET_PAD_RETURNS)
> + ? ? ? ix86_pad_returns ();
> + ? ? ?if (TARGET_FOUR_JUMP_LIMIT)
> + ? ? ? ix86_avoid_jump_misspredicts ();
> + ? ?}
> ?}
>
> ?/* Return nonzero when QImode register that must be represented via REX prefix
>