Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2014-01-08 Thread Richard Biener
On Wed, 8 Jan 2014, Kugan wrote: On 07/01/14 23:23, Richard Biener wrote: On Tue, 7 Jan 2014, Kugan wrote: [snip] Note that VIEW_CONVERT_EXPR is wrong here. I think you are handling this wrong still. From a quick look you want to avoid the actual promotion for reg_1 =

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2014-01-07 Thread Kugan
ping ? I have reorganised the last patch and now handling only VIEW_CONVERT_EXPR, CONVERT_EXPR and NOP_EXPR. Once it is reviewed and necessary changes are made, I will address the other cases as a separate patch (when it reaches that stage). Thanks, Kugan gcc/ +2014-01-07 Kugan

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2014-01-07 Thread Richard Biener
On Tue, 7 Jan 2014, Kugan wrote: ping ? I have reorganised the last patch and now handling only VIEW_CONVERT_EXPR, CONVERT_EXPR and NOP_EXPR. Once it is reviewed and necessary changes are made, I will address the other cases as a separate patch (when it reaches that stage). Note that

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2014-01-07 Thread Kugan
On 07/01/14 23:23, Richard Biener wrote: On Tue, 7 Jan 2014, Kugan wrote: [snip] Note that VIEW_CONVERT_EXPR is wrong here. I think you are handling this wrong still. From a quick look you want to avoid the actual promotion for reg_1 = when reg_1 is promoted and thus the

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-12-05 Thread Kugan
tem = (char) 255 + (char) 1; tem is always of type 'char' in GIMPLE (even if later promoted via PROMOTE_MODE) the value-range is a 'char' value-range and thus never will exceed [CHAR_MIN, CHAR_MAX]. The only way you can use that directly is if you can rely on undefined behavior

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-10-22 Thread Kugan
tem = (char) 255 + (char) 1; which has a value-range of [0,0] but clearly when computed in SImode the value-range is [256, 256]. That is, VRP computes value-ranges in the expression type, not in some arbitrary larger type. So what you'd have to do is take the value-ranges of the two

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-10-18 Thread Richard Biener
On Wed, 16 Oct 2013, Kugan wrote: Thanks Richard for the review. On 15/10/13 23:55, Richard Biener wrote: On Tue, 15 Oct 2013, Kugan wrote: Hi Eric, Can you please help to review this patch? http://gcc.gnu.org/ml/gcc-patches/2013-10/msg00452.html I think that

[PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-10-15 Thread Kugan
Hi Eric, Can you please help to review this patch? http://gcc.gnu.org/ml/gcc-patches/2013-10/msg00452.html Thanks, Kugan +2013-09-25 Kugan Vivekanandarajah kug...@linaro.org + + * dojump.c (do_compare_and_jump): Generate rtl without + zero/sign extension if redundant. + *

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-10-15 Thread Richard Biener
On Tue, 15 Oct 2013, Kugan wrote: Hi Eric, Can you please help to review this patch? http://gcc.gnu.org/ml/gcc-patches/2013-10/msg00452.html I think that gimple_assign_is_zero_sign_ext_redundant and its description is somewhat confused. You seem to have two cases here, one being NOP_EXPR

Re: [PING^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-10-15 Thread Kugan
Thanks Richard for the review. On 15/10/13 23:55, Richard Biener wrote: On Tue, 15 Oct 2013, Kugan wrote: Hi Eric, Can you please help to review this patch? http://gcc.gnu.org/ml/gcc-patches/2013-10/msg00452.html I think that gimple_assign_is_zero_sign_ext_redundant and its description

[ping^2][PATCH][2 of 2] RTL expansion for zero sign extension elimination with VRP

2013-06-21 Thread Kugan
Hi Eric, Can you please help to review the general idea and this patch for zero sign extension elimination with VRP? Thanks, Kugan On 17/06/13 11:01, Kugan wrote: Can you please help to review this patch? Richard reviewed the original patch and asked it to be split into two parts. Also,