RFA: hook doc patch (87/112): TARGET_OPTION_PRAGMA_PARSE (revised)
Joern Rennecke
joern.rennecke@embecosm.com
Fri Feb 5 00:44:00 GMT 2010
Quoting "Joseph S. Myers" <joseph@codesourcery.com>:
>> TARGET_OPTION_PRAGMA_PARSE
>> http://gcc.gnu.org/ml/gcc-patches/2010-01/msg00821.html
>
> This says what happens if args is NULL, but says nothing about the meaning
> of a non-NULL value (presumably it's not simply a boolean, or it would be
> bool rather than tree). Nor is anything said about *how* pop_target
> "specifies the default options to use" (even a reference to code that
> defines how options correspond to trees, for example).
-------------- next part --------------
2010-02-05 Joern Rennecke <joern.rennecke@embecosm.com>
* doc/tm.texi (TARGET_OPTION_PRAGMA_PARSE): Fix argument list.
Fix TARGET_OPTION_VALID_ATTRIBUTE_P name. Document arguments and
return value.
Index: doc/tm.texi
===================================================================
--- doc/tm.texi (revision 156503)
+++ doc/tm.texi (working copy)
@@ -9555,11 +9568,19 @@ information in the @var{struct cl_target
function specific options.
@end deftypefn
-@deftypefn {Target Hook} bool TARGET_OPTION_PRAGMA_PARSE (target @var{args})
+@deftypefn {Target Hook} bool TARGET_OPTION_PRAGMA_PARSE (tree @var{args}, tree @var{pop_target})
This target hook parses the options for @code{#pragma GCC option} to
set the machine specific options for functions that occur later in the
input stream. The options should be the same as handled by the
-@code{TARGET_VALID_OPTION_ATTRIBUTE_P} hook.
+@code{TARGET_OPTION_VALID_ATTRIBUTE_P} hook.
+If @var{args} is non-NULL, it is a chain of string constants, each of
+which represents an option inside the @code{#pragma GCC option}.
+If @var{args} is @code{NULL}, @var{pop_target} specifies the default
+options to use: if it is @code{NULL}, too, use
+@code{TREE_TARGET_OPTION (target_option_default_node)}; if it is non-NULL,
+use @code{TREE_TARGET_OPTION (args)}; e.g. this is suitable as an agument to
+@code{cl_target_option_restore}.
+Return @code{true} if the options are valid, and set the current state.
@end deftypefn
@deftypefn {Target Hook} bool TARGET_CAN_INLINE_P (tree @var{caller}, tree @var{callee})
More information about the Gcc-patches
mailing list