Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-16 Thread Kewen.Lin via Gcc-patches
on 2022/1/14 下午9:53, David Edelsohn wrote: > On Fri, Jan 14, 2022 at 5:42 AM Kewen.Lin wrote: >> >> on 2022/1/13 下午11:15, David Edelsohn wrote: >>> On Thu, Jan 13, 2022 at 7:40 AM Kewen.Lin wrote: Hi David, on 2022/1/13 上午11:12, David Edelsohn wrote: > On Wed, Jan 12,

Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-14 Thread David Edelsohn via Gcc-patches
On Fri, Jan 14, 2022 at 5:42 AM Kewen.Lin wrote: > > on 2022/1/13 下午11:15, David Edelsohn wrote: > > On Thu, Jan 13, 2022 at 7:40 AM Kewen.Lin wrote: > >> > >> Hi David, > >> > >> on 2022/1/13 上午11:12, David Edelsohn wrote: > >>> On Wed, Jan 12, 2022 at 8:56 PM Kewen.Lin wrote: > >

Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-14 Thread Kewen.Lin via Gcc-patches
on 2022/1/13 下午11:15, David Edelsohn wrote: > On Thu, Jan 13, 2022 at 7:40 AM Kewen.Lin wrote: >> >> Hi David, >> >> on 2022/1/13 上午11:12, David Edelsohn wrote: >>> On Wed, Jan 12, 2022 at 8:56 PM Kewen.Lin wrote: Hi, This patch is to clean up some codes with

Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-13 Thread David Edelsohn via Gcc-patches
On Thu, Jan 13, 2022 at 7:40 AM Kewen.Lin wrote: > > Hi David, > > on 2022/1/13 上午11:12, David Edelsohn wrote: > > On Wed, Jan 12, 2022 at 8:56 PM Kewen.Lin wrote: > >> > >> Hi, > >> > >> This patch is to clean up some codes with GET_MODE_UNIT_SIZE or > >> GET_MODE_NUNITS, which can use known

Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-13 Thread Kewen.Lin via Gcc-patches
Hi David, on 2022/1/13 上午11:12, David Edelsohn wrote: > On Wed, Jan 12, 2022 at 8:56 PM Kewen.Lin wrote: >> >> Hi, >> >> This patch is to clean up some codes with GET_MODE_UNIT_SIZE or >> GET_MODE_NUNITS, which can use known constant instead. > > I'll let Segher decide, but often the additional

Re: [PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-12 Thread David Edelsohn via Gcc-patches
On Wed, Jan 12, 2022 at 8:56 PM Kewen.Lin wrote: > > Hi, > > This patch is to clean up some codes with GET_MODE_UNIT_SIZE or > GET_MODE_NUNITS, which can use known constant instead. I'll let Segher decide, but often the additional code is useful self-documentation instead of magic constants. Or

[PATCH] rs6000: Use known constant for GET_MODE_NUNITS and similar

2022-01-12 Thread Kewen.Lin via Gcc-patches
Hi, This patch is to clean up some codes with GET_MODE_UNIT_SIZE or GET_MODE_NUNITS, which can use known constant instead. Bootstrapped and regtested on powerpc64le-linux-gnu P9 and powerpc64-linux-gnu P8. Is it ok for trunk? BR, Kewen - gcc/ChangeLog: * config/rs6000/altivec.md