Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-12 Thread Caio Marcelo de Oliveira Filho
Just saw your patch. I'll review that one then :-) On Tue, Feb 12, 2019 at 09:38:32AM -0800, Caio Marcelo de Oliveira Filho wrote: > Hi Juan, > > On Tue, Feb 12, 2019 at 04:37:23PM +0100, Juan A. Suarez Romero wrote: > > On Fri, 2019-02-08 at 15:39 -0600, Jason Ekstrand wrote: > > > I had a

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-12 Thread Juan A. Suarez Romero
On Tue, 2019-02-12 at 09:38 -0800, Caio Marcelo de Oliveira Filho wrote: > Hi Juan, > > On Tue, Feb 12, 2019 at 04:37:23PM +0100, Juan A. Suarez Romero wrote: > > On Fri, 2019-02-08 at 15:39 -0600, Jason Ekstrand wrote: > > > I had a chat with Caio about this and I'm skeptical. In general, users

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-12 Thread Caio Marcelo de Oliveira Filho
Hi Juan, On Tue, Feb 12, 2019 at 04:37:23PM +0100, Juan A. Suarez Romero wrote: > On Fri, 2019-02-08 at 15:39 -0600, Jason Ekstrand wrote: > > I had a chat with Caio about this and I'm skeptical. In general, users of > > the CF manipulation code shouldn't be stitching two blocks together where

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-12 Thread Juan A. Suarez Romero
On Fri, 2019-02-08 at 15:39 -0600, Jason Ekstrand wrote: > I had a chat with Caio about this and I'm skeptical. In general, users of > the CF manipulation code shouldn't be stitching two blocks together where the > first contains a jump and the second is non-empty. If the caller knows that >

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-11 Thread Juan A. Suarez Romero
On Fri, 2019-02-08 at 15:39 -0600, Jason Ekstrand wrote: > I had a chat with Caio about this and I'm skeptical. In general, users of > the CF manipulation code shouldn't be stitching two blocks together where the > first contains a jump and the second is non-empty. If the caller knows that >

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-11 Thread Juan A. Suarez Romero
On Fri, 2019-02-08 at 10:29 -0800, Ian Romanick wrote: > On 2/8/19 5:21 AM, Juan A. Suarez Romero wrote: > > On Sat, 2019-01-26 at 08:37 -0800, Jason Ekstrand wrote: > > > This makes me a bit nervous. I'll have to look at it in more detail. > > > > > > > Did you have time to take a look at this?

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-08 Thread Jason Ekstrand
I had a chat with Caio about this and I'm skeptical. In general, users of the CF manipulation code shouldn't be stitching two blocks together where the first contains a jump and the second is non-empty. If the caller knows that this case is ok, then they can check for it and empty out the one

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-08 Thread Ian Romanick
On 2/8/19 5:21 AM, Juan A. Suarez Romero wrote: > On Sat, 2019-01-26 at 08:37 -0800, Jason Ekstrand wrote: >> This makes me a bit nervous. I'll have to look at it in more detail. >> > > Did you have time to take a look at this? Is there a test case that hits this? Was it found by inspection?

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-02-08 Thread Juan A. Suarez Romero
On Sat, 2019-01-26 at 08:37 -0800, Jason Ekstrand wrote: > This makes me a bit nervous. I'll have to look at it in more detail. > Did you have time to take a look at this? J.A. > On January 25, 2019 09:37:52 "Juan A. Suarez Romero" > wrote: > > > When stitching two blocks A and B,

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-01-26 Thread Jason Ekstrand
This makes me a bit nervous. I'll have to look at it in more detail. On January 25, 2019 09:37:52 "Juan A. Suarez Romero" wrote: When stitching two blocks A and B, where A's last instruction is a jump, it is not required that B is empty; it can be plainly removed. This can happen in a

Re: [Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-01-26 Thread Caio Marcelo de Oliveira Filho
This patch is Reviewed-by: Caio Marcelo de Oliveira Filho On Fri, Jan 25, 2019 at 06:37:33PM +0100, Juan A. Suarez Romero wrote: > When stitching two blocks A and B, where A's last instruction is a jump, > it is not required that B is empty; it can be plainly removed. > > This can happen in a

[Mesa-dev] [PATCH] nir: allow stitching of non-empty block

2019-01-25 Thread Juan A. Suarez Romero
When stitching two blocks A and B, where A's last instruction is a jump, it is not required that B is empty; it can be plainly removed. This can happen in a situation like this: vec1 1 ssa_1 = load_const (true) vec1 1 ssa_2 = load_const (false) block block_1: [...] loop { vec1 ssa_3 = phi