[PATCH v3,rs6000] Add built-in function support for Power9 byte instructions

Sandra Loosemore sandra@codesourcery.com
Wed Dec 14 04:56:00 GMT 2016


On 12/12/2016 05:40 PM, Kelvin Nilsen wrote:

> @@ -15105,6 +15109,24 @@ If all of the enabled test conditions are false, t
>   The @code{scalar_test_neg} built-in functions return a non-zero value
>   if their @code{source} argument holds a negative value.
>
> +The @code{__builtin_byte_in_set} function requires a
> +64-bit environment supporting ISA 3.0 or later.  This function returns
> +a non-zero value if and only if its @code{u} argument exactly equals one of
> +the eight bytes contained within its 64-bit @code{set} argument.
> +
> +The @code{__builtin_byte_in_range} and
> +@code{__builtin_byte_in_either_range} require an environment
> +supporting ISA 3.0 or later.  For these two functions, the
> +@code{range} argument is encoded as 4 bytes, organized as
> +@code{hi_1:lo_1:hi_2:lo_2}.
> +The first of these functions returns a
> +non-zero value if and only if its @code{u} argument is within the
> +range bounded between @code{lo_2} and @code{hi_2} inclusive.
> +The second of these functions returns non-zero if and only
> +if its @code{u} argument is either within the range bounded between
> +@code{lo_1} and @code{hi_1} inclusive or is within the range bounded between
> +@code{lo_2} and @code{hi_2} inclusive.

I would prefer that you refer to the functions by name instead of "the 
first/second of these functions".

Also, you have a parallel construction problem in the second sentence: 
"is either within... or is within...".  I suggest rephrasing as "is 
within either...  or...".

-Sandra the nit-picky



More information about the Gcc-patches mailing list