[PATCH] OpenMP simd if clause support with runtime determined argument

2019-05-15 Thread Jakub Jelinek
Hi! The following patch implements what I've failed to do in time for 9.x, in particular, if #pragma omp simd has if clause and the argument is not constant zero (handled by the previous patch), or constant non-zero (ignored, we want normal vectorization in that case as before), this patch arrange

Re: [PATCH] OpenMP simd if clause support with runtime determined argument

2019-05-16 Thread Richard Biener
On Wed, 15 May 2019, Jakub Jelinek wrote: > Hi! > > The following patch implements what I've failed to do in time for 9.x, > in particular, if #pragma omp simd has if clause and the argument is > not constant zero (handled by the previous patch), or constant non-zero > (ignored, we want normal ve

Re: [PATCH] OpenMP simd if clause support with runtime determined argument

2019-05-16 Thread Jakub Jelinek
On Thu, May 16, 2019 at 09:53:06AM +0200, Richard Biener wrote: > > + if (nonconst_simd_if) > > +{ > > + if (sctx.lane == NULL_TREE) > > + { > > + sctx.idx = create_tmp_var (unsigned_type_node); > > + sctx.lane = create_tmp_var (unsigned_type_node); > > + } > > Does forcing a

Re: [PATCH] OpenMP simd if clause support with runtime determined argument

2019-05-16 Thread Richard Biener
On Thu, 16 May 2019, Jakub Jelinek wrote: > On Thu, May 16, 2019 at 09:53:06AM +0200, Richard Biener wrote: > > > + if (nonconst_simd_if) > > > +{ > > > + if (sctx.lane == NULL_TREE) > > > + { > > > + sctx.idx = create_tmp_var (unsigned_type_node); > > > + sctx.lane = create_tmp_var

[PATCH] OpenMP simd if clause support with runtime determined argument (take 2)

2019-05-16 Thread Jakub Jelinek
On Thu, May 16, 2019 at 11:30:38AM +0200, Richard Biener wrote: > > note_simd_array_uses indeed does walk the IL and does look at the calls, > > but I'd need some data structure where to store the argument; we don't have > > loop_vinfo yet (we don't have it even before the loop over vector sizes),

Re: [PATCH] OpenMP simd if clause support with runtime determined argument (take 2)

2019-05-16 Thread Richard Biener
On Thu, 16 May 2019, Jakub Jelinek wrote: > On Thu, May 16, 2019 at 11:30:38AM +0200, Richard Biener wrote: > > > note_simd_array_uses indeed does walk the IL and does look at the calls, > > > but I'd need some data structure where to store the argument; we don't > > > have > > > loop_vinfo yet (