Re: [Mesa-dev] [PATCH 2/2] nir: fix bug with moves in nir_opt_remove_phis()

2016-09-02 Thread Kenneth Graunke
On Friday, September 2, 2016 7:28:09 PM PDT Connor Abbott wrote: > In 144cbf8 ("nir: Make nir_opt_remove_phis see through moves."), Ken > made nir_opt_remove_phis able to coalesce phi nodes whose sources are > all moves with the same swizzle. However, he didn't add the logic > necessary for handlin

Re: [Mesa-dev] [PATCH 2/2] nir: fix bug with moves in nir_opt_remove_phis()

2016-09-02 Thread Connor Abbott
On Fri, Sep 2, 2016 at 8:48 PM, Jason Ekstrand wrote: > I think this is conceptually correct but I haven't reviewed it for complete > correctness yet or tested it. > > That said, I think this is just a special case of the phi distribution pass > that we talked about on IRC a bit today. Maybe we s

Re: [Mesa-dev] [PATCH 2/2] nir: fix bug with moves in nir_opt_remove_phis()

2016-09-02 Thread Jason Ekstrand
I think this is conceptually correct but I haven't reviewed it for complete correctness yet or tested it. That said, I think this is just a special case of the phi distribution pass that we talked about on IRC a bit today. Maybe we should just go ahead and implement that? For unary ALU operation

[Mesa-dev] [PATCH 2/2] nir: fix bug with moves in nir_opt_remove_phis()

2016-09-02 Thread Connor Abbott
In 144cbf8 ("nir: Make nir_opt_remove_phis see through moves."), Ken made nir_opt_remove_phis able to coalesce phi nodes whose sources are all moves with the same swizzle. However, he didn't add the logic necessary for handling the fact that the phi may now have multiple different sources, even tho