Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Connor Abbott
On Tue, Aug 30, 2016 at 12:40 AM, Matt Turner wrote: > On Mon, Aug 29, 2016 at 9:06 PM, Timothy Arceri > wrote: >> Can't the phi have more than one source from before the loop? e.g >> >>int i = 0; >>if (somthing) >> i = 1; >>else

Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Matt Turner
On Mon, Aug 29, 2016 at 9:06 PM, Timothy Arceri wrote: > Can't the phi have more than one source from before the loop? e.g > >int i = 0; >if (somthing) > i = 1; >else > i = 2; > >for ( ; i < 5; i++) > do_stuff(i); In fact, no. :)

Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Timothy Arceri
On Tue, 2016-08-30 at 14:16 +1000, Timothy Arceri wrote: > On Tue, 2016-08-30 at 14:06 +1000, Timothy Arceri wrote: > > > > On Mon, 2016-08-29 at 20:34 -0400, Connor Abbott wrote: > > > > > > > > > On Mon, Aug 29, 2016 at 12:59 AM, Timothy Arceri > > > wrote: > >

Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Timothy Arceri
On Tue, 2016-08-30 at 14:06 +1000, Timothy Arceri wrote: > On Mon, 2016-08-29 at 20:34 -0400, Connor Abbott wrote: > > > > On Mon, Aug 29, 2016 at 12:59 AM, Timothy Arceri > > wrote: > > > > > > > > > --- > > >  src/compiler/Makefile.sources  |   1 + > > >

Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Timothy Arceri
On Mon, 2016-08-29 at 20:34 -0400, Connor Abbott wrote: > On Mon, Aug 29, 2016 at 12:59 AM, Timothy Arceri > wrote: > > > > --- > >  src/compiler/Makefile.sources  |   1 + > >  src/compiler/nir/nir.h |   2 + > >  

Re: [Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-29 Thread Connor Abbott
On Mon, Aug 29, 2016 at 12:59 AM, Timothy Arceri wrote: > --- > src/compiler/Makefile.sources | 1 + > src/compiler/nir/nir.h | 2 + > src/compiler/nir/nir_opt_loop_unroll.c | 394 > + > 3 files changed,

[Mesa-dev] [PATCH 12/13] nir: add a loop unrolling pass

2016-08-28 Thread Timothy Arceri
--- src/compiler/Makefile.sources | 1 + src/compiler/nir/nir.h | 2 + src/compiler/nir/nir_opt_loop_unroll.c | 394 + 3 files changed, 397 insertions(+) create mode 100644 src/compiler/nir/nir_opt_loop_unroll.c diff --git