Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-09 Thread Richard Sandiford via Gcc-patches
Segher Boessenkool writes: > On Wed, Mar 08, 2023 at 11:58:51AM +, Richard Sandiford wrote: >> Segher Boessenkool writes: >> > An #ifdef is a way of making a change that is not finished yet not hurt >> > the other targets. It still hurts generic development, which indirectly >> > hurts all t

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-08 Thread Segher Boessenkool
On Wed, Mar 08, 2023 at 11:58:51AM +, Richard Sandiford wrote: > Segher Boessenkool writes: > > An #ifdef is a way of making a change that is not finished yet not hurt > > the other targets. It still hurts generic development, which indirectly > > hurts all targets. > > Seems like this might

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-08 Thread Richard Sandiford via Gcc-patches
Segher Boessenkool writes: > Hi! > > On Mon, Mar 06, 2023 at 07:13:08PM +, Richard Sandiford wrote: >> Segher Boessenkool writes: >> > Most importantly, what makes you think this is a problem for aarch64 >> > only? If it actually is, you can fix it in the aarch64 config! Either >> > with or

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Segher Boessenkool
Hi! On Mon, Mar 06, 2023 at 07:13:08PM +, Richard Sandiford wrote: > Segher Boessenkool writes: > > Most importantly, what makes you think this is a problem for aarch64 > > only? If it actually is, you can fix it in the aarch64 config! Either > > with or without new hooks, whatever works be

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Segher Boessenkool
On Mon, Mar 06, 2023 at 04:34:59PM +, Richard Sandiford wrote: > Jakub Jelinek writes: > > On Mon, Mar 06, 2023 at 03:08:00PM +, Richard Sandiford via Gcc-patches > > wrote: > >> Segher Boessenkool writes: > >> > On Mon, Mar 06, 2023 at 12:47:06PM +, Richard Sandiford wrote: > >> >>

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Richard Sandiford via Gcc-patches
Segher Boessenkool writes: > On Mon, Mar 06, 2023 at 04:34:59PM +, Richard Sandiford wrote: >> Jakub Jelinek writes: >> > Could we have a target hook to canonicalize memory addresses for combiner, >> > like we have that targetm.canonicalize_comparison ? >> >> I don't think a hook makes sense

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Segher Boessenkool
On Mon, Mar 06, 2023 at 04:34:59PM +, Richard Sandiford wrote: > Jakub Jelinek writes: > > Could we have a target hook to canonicalize memory addresses for combiner, > > like we have that targetm.canonicalize_comparison ? > > I don't think a hook makes sense as a long-term design decision. >

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Segher Boessenkool
On Mon, Mar 06, 2023 at 05:18:50PM +0100, Jakub Jelinek wrote: > On Mon, Mar 06, 2023 at 03:08:00PM +, Richard Sandiford via Gcc-patches > wrote: > That still feels like it could be risky in stage4, affecting various other > FEs which would be expecting ANDs in their patterns instead of *_EXTE

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Richard Sandiford via Gcc-patches
Jakub Jelinek writes: > On Mon, Mar 06, 2023 at 03:08:00PM +, Richard Sandiford via Gcc-patches > wrote: >> Segher Boessenkool writes: >> > On Mon, Mar 06, 2023 at 12:47:06PM +, Richard Sandiford wrote: >> >> How about the patch below? >> > >> > What about it? What would make it any bet

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Jakub Jelinek via Gcc-patches
On Mon, Mar 06, 2023 at 03:08:00PM +, Richard Sandiford via Gcc-patches wrote: > Segher Boessenkool writes: > > On Mon, Mar 06, 2023 at 12:47:06PM +, Richard Sandiford wrote: > >> How about the patch below? > > > > What about it? What would make it any better than the previous? > > It d

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Richard Sandiford via Gcc-patches
Segher Boessenkool writes: > On Mon, Mar 06, 2023 at 12:47:06PM +, Richard Sandiford wrote: >> How about the patch below? > > What about it? What would make it any better than the previous? It does what Jeff suggested in the quoted message: work within the existing extract/make_compound_oper

Re: [PATCH] combine: Try harder to form zero_extends [PR106594]

2023-03-06 Thread Segher Boessenkool
On Mon, Mar 06, 2023 at 12:47:06PM +, Richard Sandiford wrote: > How about the patch below? What about it? What would make it any better than the previous? Oh, and please do not send new patches in old threads :-( Segher