[RFC] [ipa bitwise cp] tree-ssa-ccp changes

Richard Biener rguenther@suse.de
Tue Aug 9 09:28:00 GMT 2016


On Mon, 8 Aug 2016, Prathamesh Kulkarni wrote:

> Hi Richard,
> In the attached version, I tried to address your suggestions from:
> https://gcc.gnu.org/ml/gcc-patches/2016-08/msg00279.html
> 
> In ccp_finalize we do:
> wide_int nonzero_bits = wide_int::from (val->mask, precision,
>                                                   UNSIGNED) | val->value;
> 
> Similar to the change to extend_mask to extend based on signop,
> should this be changed to:
> wide_int::from (val->mask, precision, TYPE_SIGN (TREE_TYPE (val->value))) ?
> (although I guess we are narrowing the type here rather than extending).

Yeah, we're truncating here so it doesn't really matter what sign the
larger mask has.

The patch is ok if the IPA bits are approved.

Thanks,
Richard.



More information about the Gcc-patches mailing list