[PATCH v5] dse: Remove partial load after full store for high part access[PR71309]

luoxhu luoxhu@linux.ibm.com
Wed Aug 5 23:30:02 GMT 2020


Hi Richard,

On 2020/8/3 22:01, Richard Sandiford wrote:
>>         /* Try a wider mode if truncating the store mode to NEW_MODE
>>   	 requires a real instruction.  */
>>         if (maybe_lt (GET_MODE_SIZE (new_mode), GET_MODE_SIZE (store_mode))
>> @@ -1779,6 +1780,25 @@ find_shift_sequence (poly_int64 access_size,
>>   	  && !targetm.modes_tieable_p (new_mode, store_mode))
>>   	continue;
>>   
>> +      if (multiple_p (GET_MODE_BITSIZE (new_mode), shift)
> 
> Like I mentioned before, this should be the other way around:
> 
>      multiple_p (shift, GET_MODE_BITSIZE (new_mode))
> 
> i.e. for the subreg to be valid, the shift amount must be a multiple
> of the outer mode size in bits.
> 
> OK with that change, thanks, and sorry for the multiple review cycles.

Just had another question is do we want to backport this patch to gcc-10
and gcc-9 branches? :)


Xionghu


> 
> Richard
> 


More information about the Gcc-patches mailing list