Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-13 Thread Ian Romanick
On 01/12/2016 05:41 PM, Matt Turner wrote: > On Tue, Jan 12, 2016 at 4:10 PM, Jason Ekstrand wrote: >> On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner wrote: >>> >>> On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand >>> wrote: This

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-13 Thread Jason Ekstrand
On Wed, Jan 13, 2016 at 2:14 PM, Matt Turner wrote: > On Wed, Jan 13, 2016 at 1:46 PM, Jason Ekstrand > wrote: > > On Wed, Jan 13, 2016 at 2:01 AM, Ian Romanick > wrote: > >> On 01/12/2016 05:41 PM, Matt Turner wrote: > >> >

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-13 Thread Jason Ekstrand
On Wed, Jan 13, 2016 at 2:01 AM, Ian Romanick wrote: > On 01/12/2016 05:41 PM, Matt Turner wrote: > > On Tue, Jan 12, 2016 at 4:10 PM, Jason Ekstrand > wrote: > >> On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner > wrote: > >>> > >>>

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-13 Thread Matt Turner
On Wed, Jan 13, 2016 at 1:46 PM, Jason Ekstrand wrote: > On Wed, Jan 13, 2016 at 2:01 AM, Ian Romanick wrote: >> On 01/12/2016 05:41 PM, Matt Turner wrote: >> > Section 8.3.2 of the OpenCL C 2.0 spec is also relevant, but doesn't >> > touch directly on

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Ian Romanick
With the SPIR-V link added and the wording change suggested by Erik RE: precision vs. number of bits in the type, this series is Reviewed-by: Ian Romanick At some point we should add a debug mode that inserts these operations in GLSL ES shaders around mediump and lowp

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Jason Ekstrand
On Tue, Jan 12, 2016 at 4:50 PM, Ian Romanick wrote: > With the SPIR-V link added and the wording change suggested by Erik RE: > precision vs. number of bits in the type, this series is > How about: This opcode takes a 32-bit floating-point value and reduces its precision

[Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Jason Ekstrand
This opcode simply takes a 32-bit floating-point value and reduces its effective precision to 16 bits. --- src/glsl/nir/nir_opcodes.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/glsl/nir/nir_opcodes.py b/src/glsl/nir/nir_opcodes.py index d31507f..9dbb341 100644 ---

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Matt Turner
On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand wrote: > This opcode simply takes a 32-bit floating-point value and reduces its > effective precision to 16 bits. > --- What's it supposed to do for values not representable in half-precision? I think we need some more

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Erik Faye-Lund
On Wed, Jan 13, 2016 at 1:10 AM, Jason Ekstrand wrote: > On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner wrote: >> >> On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand >> wrote: >> > This opcode simply takes a 32-bit floating-point

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Jason Ekstrand
On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner wrote: > On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand > wrote: > > This opcode simply takes a 32-bit floating-point value and reduces its > > effective precision to 16 bits. > > --- > > What's it supposed

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Roland Scheidegger
Am 13.01.2016 um 02:23 schrieb Jason Ekstrand: > On Tue, Jan 12, 2016 at 4:50 PM, Ian Romanick > wrote: > > With the SPIR-V link added and the wording change suggested by Erik RE: > precision vs. number of bits in the type, this series

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Matt Turner
On Tue, Jan 12, 2016 at 4:10 PM, Jason Ekstrand wrote: > On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner wrote: >> >> On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand >> wrote: >> > This opcode simply takes a 32-bit floating-point

Re: [Mesa-dev] [PATCH 1/2] nir: Add a fquantize2f16 opcode

2016-01-12 Thread Roland Scheidegger
Am 13.01.2016 um 02:41 schrieb Matt Turner: > On Tue, Jan 12, 2016 at 4:10 PM, Jason Ekstrand wrote: >> On Tue, Jan 12, 2016 at 3:52 PM, Matt Turner wrote: >>> >>> On Tue, Jan 12, 2016 at 3:35 PM, Jason Ekstrand >>> wrote: