Hello Peter:

On 23/03/23 6:08 pm, Peter Bergner wrote:
> On 3/23/23 5:38 AM, Ajit Agarwal wrote:
>> This patch removed unnecessary signed extension elimination in ree pass.
>> Bootstrapped and regtested on powerpc64-linux-gnu.
>>
>>
>> Thanks & Regards
>> Ajit
>>
>>      rtl-optimization: ppc backend generates unnecessary signed extension.
>>
>>      Eliminate unnecessary redundant signed extension.
>>
>>      2023-03-23  Ajit Kumar Agarwal  <aagar...@linux.ibm.com>
>>
>> gcc/ChangeLog:
>>
>>      * ree.cc: Modification for  AND opcode support to eliminate
>>      unnecessary signed extension.
>>      * testsuite/g++.target/powerpc/sext-elim.C: New tests.
> 
> Not a review of the patch, but we talked offline about other bugzillas
> regarding unnecessary sign and zero extensions.  Doing a quick scan, I
> see the following bugs.  Please have a look at 1) whether these are
> still a problem with unpatched trunk, and if they are, 2) whether your
> patch fixes them or could fix them.  Thanks.
> 
>     https://gcc.gnu.org/PR41742

These are not addressed in the trunk patch, because int c is not initialized 
with registers and for this reason we cannot eliminate them. If we initialize 
int c then zero extension goes away.

>     https://gcc.gnu.org/PR65010
>     https://gcc.gnu.org/PR82940
>     https://gcc.gnu.org/PR107949
>

My patch fixes these PR's which were not fixed in trunk patch.

Thanks & Regards
Ajit
 
> Peter
> 

Reply via email to