Re: [PATCH] Handle right shifts by zero in range-ops.

2020-10-20 Thread Aldy Hernandez via Gcc-patches
On 10/19/20 4:22 PM, Jakub Jelinek wrote: On Mon, Oct 19, 2020 at 10:19:48AM -0400, Andrew MacLeod via Gcc-patches wrote: On 10/19/20 5:38 AM, Aldy Hernandez wrote: If the shift amount in operator_lshift::op1_range was zero, an invalid range of [1, 0] was being created. Should we do the sa

Re: [PATCH] Handle right shifts by zero in range-ops.

2020-10-19 Thread Jakub Jelinek via Gcc-patches
On Mon, Oct 19, 2020 at 10:19:48AM -0400, Andrew MacLeod via Gcc-patches wrote: > On 10/19/20 5:38 AM, Aldy Hernandez wrote: > > If the shift amount in operator_lshift::op1_range was zero, an invalid range > > of [1, 0] was being created. > > Should we do the same thing with rshift::op1_range?  

Re: [PATCH] Handle right shifts by zero in range-ops.

2020-10-19 Thread Andrew MacLeod via Gcc-patches
On 10/19/20 5:38 AM, Aldy Hernandez wrote: If the shift amount in operator_lshift::op1_range was zero, an invalid range of [1, 0] was being created. Should we do the same thing with rshift::op1_range? ie, return the LHS if the shift is 0 instead of trying to figure it out Pushed.