[PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-16 Thread juzhe . zhong
From: Ju-Zhe Zhong This patch implement decrement IV for length approach in loop control. Address comment from kewen that incorporate the implementation inside "vect_set_loop_controls_directly" instead of a standalone function. Address comment from Richard using MIN_EXPR to handle these 3 follo

RE: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-18 Thread Li, Pan2 via Gcc-patches
u-Zhe Zhong Subject: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer From: Ju-Zhe Zhong This patch implement decrement IV for length approach in loop control. Address comment from kewen that incorporate the implementation inside "vect_set_loop_controls_directly&quo

Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-19 Thread Richard Sandiford via Gcc-patches
Thanks for the update. I'll split this review into two pieces. Second piece to follow (not sure when, but hopefully soon). juzhe.zh...@rivai.ai writes: > diff --git a/gcc/tree-vect-loop.cc b/gcc/tree-vect-loop.cc > index ed0166fedab..6f49bdee009 100644 > --- a/gcc/tree-vect-loop.cc > +++ b/gcc/tr

Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-19 Thread Richard Sandiford via Gcc-patches
"juzhe.zh...@rivai.ai" writes: >>> I don't think this is a property of decrementing IVs. IIUC it's really >>> a property of rgl->factor == 1 && factor == 1, where factor would need >>> to be passed in by the caller. Because of that, it should probably be >>> a separate patch. > Is it right that

Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-19 Thread Richard Sandiford via Gcc-patches
"juzhe.zh...@rivai.ai" writes: > Hi, Richard. Thanks for the comments. > > Would you mind telling me whether it is possible that we can make decrement > IV support into GCC middle-end ? > > If yes, could you tell what I should do next for the patches since I am > confused that it seems the imple

Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-22 Thread Richard Biener via Gcc-patches
On Fri, May 19, 2023 at 12:59 PM Richard Sandiford via Gcc-patches wrote: > > "juzhe.zh...@rivai.ai" writes: > >>> I don't think this is a property of decrementing IVs. IIUC it's really > >>> a property of rgl->factor == 1 && factor == 1, where factor would need > >>> to be passed in by the call

Re: Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-19 Thread juzhe.zh...@rivai.ai
n elements rather than bytes. >> So I think the above part of the patch should go in ahead of the IV changes. >> But the test should be based on factor rather than >> TYPE_VECTOR_SUBPARTS.Since the length control measured by bytes instead of >> bytes is not appropriate for

Re: Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-19 Thread juzhe.zh...@rivai.ai
abandoned and need to rewrite the whole thing. Would you mind giving me more information? Thanks. juzhe.zh...@rivai.ai From: Richard Sandiford Date: 2023-05-19 18:23 To: juzhe.zhong CC: gcc-patches; rguenther Subject: Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer Thanks for

Re: Re: [PATCH V11] VECT: Add decrement IV support in Loop Vectorizer

2023-05-22 Thread juzhe.zh...@rivai.ai
ue for RVV). So you could image I will post more middle-end patches for RVV auto-vectorization in the future. Thanks. juzhe.zh...@rivai.ai From: Richard Biener Date: 2023-05-22 18:12 To: Richard Sandiford; juzhe.zh...@rivai.ai; gcc-patches; rguenther Subject: Re: [PATCH V11] VECT: Add decreme