[Piglit] [PATCH v2] glsl-1.10: test bug with lessThan() when the input expression has mixed sizes

Timothy Arceri tarceri at itsqueeze.com
Wed Jun 27 23:05:20 UTC 2018


On 28/06/18 08:58, Ian Romanick wrote:
> On 06/27/2018 03:44 PM, Timothy Arceri wrote:
>> On 28/06/18 08:28, Timothy Arceri wrote:
>>> On 27/06/18 21:58, Tapani Pälli wrote:
>>>> On 06/27/2018 02:43 PM, Timothy Arceri wrote:
>>>>> ---
>>>>>
>>>>>    V2: Fix some spelling typos and the commit description
>>>>>
>>>>>    ...on-vec4-mixed-arithmetic-input.shader_test | 37
>>>>> +++++++++++++++++++
>>>>>    1 file changed, 37 insertions(+)
>>>>>    create mode 100644
>>>>> tests/spec/glsl-1.10/execution/comparision-vec4-mixed-arithmetic-input.shader_test
>>>>>
>>>>>
>>>>> diff --git
>>>>> a/tests/spec/glsl-1.10/execution/comparision-vec4-mixed-arithmetic-input.shader_test
>>>>> b/tests/spec/glsl-1.10/execution/comparision-vec4-mixed-arithmetic-input.shader_test
>>>>>
>>>>> new file mode 100644
>>>>> index 000000000..78f0068a3
>>>>> --- /dev/null
>>>>> +++
>>>>> b/tests/spec/glsl-1.10/execution/comparision-vec4-mixed-arithmetic-input.shader_test
>>>>>
>>>>> @@ -0,0 +1,37 @@
>>>>> +# This exerises a bug found in a Doom shader were the lessThan()
>>>>> comparision
>>>>> +# was only done againsts a single component of the mixed arithmetic
>>>>> expression
>>>>
>>>> here are some more typos to fix:
>>>>
>>>> were -> where
>>>> exerises -> exercises
>>>> comparision -> comparison
>>>> againsts -> against
>>>
>>> lol, thanks.
>>>
>>>>
>>>> For me running this throws following assert:
>>>>
>>>> shader_runner: ../src/compiler/glsl/ir.cpp:491:
>>>> ir_expression::ir_expression(int, ir_rvalue*, ir_rvalue*): Assertion
>>>> `op0->type == op1->type' failed.
>>>>
>>>> Is this the issue?
>>
>> Seems to be a bug with do_tree_grafting()
> 
> Either that or in opt_algebraic.  It's turning lessThan(a + b, 0) into a
> < -b, but it's loosing all the swizzles and the sizes.
> 

Ah yes you are right. It does seem to be opt_algebraic() that is the cause.


More information about the Piglit mailing list