[PATCH] Adjust builtin-bswap-6/7

Jeff Law law@redhat.com
Fri Apr 4 17:51:00 GMT 2014


On 04/04/14 10:18, Andreas Krebbel wrote:
> Hi,
>
> the attached patch modifies the builtin-bswap-6/7 testcases in order
> to prevent GCC from using math instead of a compare.  Only with a
> compare the folding in combine actually takes place.
>
> Whether the return value is produce with a compare or not depends
> again on the value of branch cost.
>
> Ideally we would be able to do the folding also with the math trick
> but it is probably not that easy since we have already lost the
> information that in the end all we need is a 0 or a 1.
>
> Ok?
>
> Bye,
>
> -Andreas-
>
> 2014-04-04  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>
>
> 	* gcc.dg/builtin-bswap-6.c: Adjust return value to disable GCC
> 	optimization.
> 	* gcc.dg/builtin-bswap-7.c: Likewise.
OK.
Jeff



More information about the Gcc-patches mailing list