This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, committed] Add ability to set the optimization options and on ix86 target options on a function specific basis
- From: "Manuel López-Ibáñez" <lopezibanez at gmail dot com>
- To: "Michael Meissner" <gnu at the-meissners dot org>, gcc-patches at gcc dot gnu dot org, karthikkumar at gmail dot com
- Date: Wed, 23 Jul 2008 14:02:55 +0200
- Subject: Re: [PATCH, committed] Add ability to set the optimization options and on ix86 target options on a function specific basis
- References: <20080723103750.GA9075@tiktok.the-meissners.org>
2008/7/23 Michael Meissner <gnu@the-meissners.org>:
> Index: gcc/attribs.c
> ===================================================================
> --- gcc/attribs.c (revision 138074)
> +++ gcc/attribs.c (working copy)
> @@ -33,6 +33,7 @@ along with GCC; see the file COPYING3.
> #include "target.h"
> #include "langhooks.h"
> #include "hashtab.h"
> +#include "c-common.h"
Do you need to include c-common.h here? I missed the reason.
> Index: gcc/doc/extend.texi
> +On the 386, the following options are allowed:
> +
> +@table @samp
> +@item abm
> +@itemx no-abm
> +@cindex option("abm")
> +Enable/disable the generation of the advanced bit instructions.
Do you need to explain what each option means instead of giving out a
list of supported options and referring to the command-line part of
the manual ?
> +@item optimize
> +@cindex @code{optimize} function attribute
> +The @code{optimize} attribute is used to specify that a function is to
> +be compiled with different optimization options than specified on the
> +command line. Arguments can either be numbers or strings. Numbers
> +are assumed to be an optimization level. Strings that begin with
> +@code{O} are assumed to be an optimization option, while other options
> +are assumed to be used with a @code{-f} prefix. You can also use the
Have you read this paragraph to someone not familiar with your syntax?
In particular the sentence:
"Strings that begin with @code{O} are assumed to be an optimization
option, while other options
are assumed to be used with a @code{-f} prefix."
does not make any sense to me and it doesn't clarify me how to specify
the options.
> Index: gcc/doc/invoke.texi
> ===================================================================
> --- gcc/doc/invoke.texi (revision 138074)
> +++ gcc/doc/invoke.texi (working copy)
> @@ -10543,6 +10543,8 @@ code that expects temporaries to be 80bi
> This is the default choice for the x86-64 compiler.
>
> @item sse,387
> +@itemx sse+387
> +@itemx both
What will "both" mean if we ever had to add another instruction set here?
Cheers,
Manuel.