Re: [Mesa-dev] [PATCH 2/2] spirv: fix bug when OpSpecConstantOp calls a conversion

2017-12-06 Thread Ian Romanick
On 11/29/2017 02:17 AM, Samuel Iglesias Gonsálvez wrote: > On Tue, 2017-11-28 at 13:13 -0800, Ian Romanick wrote: >> On 11/20/2017 10:25 PM, Samuel Iglesias Gonsálvez wrote: >>> In that case, nir_eval_const_opcode() will evaluate the conversion >>> but as it was using destination's bit_size, the re

Re: [Mesa-dev] [PATCH 2/2] spirv: fix bug when OpSpecConstantOp calls a conversion

2017-11-28 Thread Samuel Iglesias Gonsálvez
On Tue, 2017-11-28 at 13:13 -0800, Ian Romanick wrote: > On 11/20/2017 10:25 PM, Samuel Iglesias Gonsálvez wrote: > > In that case, nir_eval_const_opcode() will evaluate the conversion > > but as it was using destination's bit_size, the resulting > > value was just a cast of the source constant val

Re: [Mesa-dev] [PATCH 2/2] spirv: fix bug when OpSpecConstantOp calls a conversion

2017-11-28 Thread Ian Romanick
On 11/20/2017 10:25 PM, Samuel Iglesias Gonsálvez wrote: > In that case, nir_eval_const_opcode() will evaluate the conversion > but as it was using destination's bit_size, the resulting > value was just a cast of the source constant value. By passing the > source's bit size, it does the conversion

[Mesa-dev] [PATCH 2/2] spirv: fix bug when OpSpecConstantOp calls a conversion

2017-11-20 Thread Samuel Iglesias Gonsálvez
In that case, nir_eval_const_opcode() will evaluate the conversion but as it was using destination's bit_size, the resulting value was just a cast of the source constant value. By passing the source's bit size, it does the conversion properly. Fixes: dEQP-VK.spirv_assembly.instruction.*.opspeccon