Re: Replacing NIR with SPIR-V?

2022-01-24 Thread Ian Romanick
On 1/23/22 12:10 PM, Dave Airlie wrote: On Sun, 23 Jan 2022 at 22:58, Abel Bernabeu wrote: Yes, NIR arrays and struct and nir_deref to deal with them but, by the time you get into the back-end, all the nir_derefs are gone and you're left with load/store messages with actual addresses

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Abel Bernabeu
I can tease you all with the promise of SIMT and fixed function units. In the meantime you can hear me talking about the work we do at the Graphics and ML Special Interest Group within RISC-V: https://www.youtube.com/watch?v=kM0lsWjqOaw I still need to make our site a bit more useful, but here

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Dave Airlie
On Mon, 24 Jan 2022 at 06:52, Abel Bernabeu wrote: > > Dave, > > Am glad for the Mesa community to support the RISC-V effort with the advice > given so far. > > I hear your concerns regarding performance. I am familiar with the Larabee > case and know some of the people who worked on that.

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Abel Bernabeu
Dave, Am glad for the Mesa community to support the RISC-V effort with the advice given so far. I hear your concerns regarding performance. I am familiar with the Larabee case and know some of the people who worked on that. However, I am not here to discuss what is the RISC-V strategy for

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Dave Airlie
On Sun, 23 Jan 2022 at 22:58, Abel Bernabeu wrote: >> >> Yes, NIR arrays and struct and nir_deref to deal with them but, by the time >> you get into the back-end, all the nir_derefs are gone and you're left with >> load/store messages with actual addresses (either a 64-bit memory address or >>

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Connor Abbott
On Sun, Jan 23, 2022 at 1:58 PM Abel Bernabeu wrote: >> >> Yes, NIR arrays and struct and nir_deref to deal with them but, by the time >> you get into the back-end, all the nir_derefs are gone and you're left with >> load/store messages with actual addresses (either a 64-bit memory address or

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Timur Kristóf
Hi Abel, On Sun, 2022-01-23 at 13:58 +0100, Abel Bernabeu wrote: > > That is the thing: there is already a community maintained LLVM > backend for RISC-V and I need to see how to get value from that > effort. And that is a very typical escenario for new architectures. > There is already an LLVM

Re: Replacing NIR with SPIR-V?

2022-01-23 Thread Abel Bernabeu
> > Yes, NIR arrays and struct and nir_deref to deal with them but, by the > time you get into the back-end, all the nir_derefs are gone and you're left > with load/store messages with actual addresses (either a 64-bit memory > address or a index+offset pair for a bound resource). Again, unless

Re: Replacing NIR with SPIR-V?

2022-01-21 Thread Marek Olšák
> - Does it make sense to move to SPIR-V? No, it doesn't make any sense whatsoever. Marek On Wed, Jan 19, 2022 at 8:17 PM Abel Bernabeu < abel.berna...@esperantotech.com> wrote: > Hi, > > My name Abel Bernabeu and I currently chair the Graphics and ML Special > Interest Group within RISC-V. >

Re: Replacing NIR with SPIR-V?

2022-01-21 Thread Alyssa Rosenzweig
>In principle, all the properties you highlight in your blog as key points >of NIR also apply to SPIR-V. Those key points are relative to GLSL IR, the IR it displaces. The purpose of SPIR-V is so different than both NIR and GLSL IR it isn't interesting to do a comparison. Comparing with

Re: Replacing NIR with SPIR-V?

2022-01-20 Thread Jason Ekstrand
On Thu, Jan 20, 2022 at 5:49 PM Abel Bernabeu < abel.berna...@esperantotech.com> wrote: > In principle, all the properties you highlight in your blog > as key points > of NIR also apply to SPIR-V. > First off, that blog post is truly

Re: Replacing NIR with SPIR-V?

2022-01-20 Thread Abel Bernabeu
In principle, all the properties you highlight in your blog as key points of NIR also apply to SPIR-V. I was curious to know where in the details that I miss, NIR starts shining as a more suitable IR than SPIR-V for the task of

Re: Replacing NIR with SPIR-V?

2022-01-19 Thread Jason Ekstrand
> - Does it make sense to move to SPIR-V? None whatsoever. SPIR-V is an interchange format, not a set of manipulatable data structures suitable for compiler lowering and optimization. You also don't want to build hardware around consuming SPIR-V. There are lots of things that the SPIR-V has

Replacing NIR with SPIR-V?

2022-01-19 Thread Abel Bernabeu
Hi, My name Abel Bernabeu and I currently chair the Graphics and ML Special Interest Group within RISC-V. As part of my work for RISC-V I am currently looking at what is needed for supporting a graphics product that uses a (potentially extended) RISC-V ISA for its shading cores. My initial focus