[Piglit] Python errors during test generation

Chad Versace chad.versace at linux.intel.com
Fri Nov 9 13:11:33 PST 2012


On 11/09/2012 12:18 PM, Paul Berry wrote:
> On 9 November 2012 11:15, Chad Versace <chad.versace at linux.intel.com> wrote:
> 
>> Paul,
>>
>> I observed these Python errors during test generation. I haven't had a
>> chance to look into them yet, but just wanted to inform you before I forgot
>> about them.
>>
>> [87/1749] Generating builtin_uniform_tests.list
>> /home/chad/proj/linux/graphics/v/master/src/piglit/generated_tests/builtin_function.py:1146:
>> RuntimeWarning: overflow encountered in uint_scalars
>>   f('op-sub', 2, 110, lambda x, y: x - y, match_simple_binop,
>> [floats+vecs+mats+ints+ivecs+uints+uvecs,
>> floats+vecs+mats+ints+ivecs+uints+uvecs], template = '({0} - {1})')
>> [127/1749] Generating constant_array_size_tests.list
>> /home/chad/proj/linux/graphics/v/master/src/piglit/generated_tests/builtin_function.py:1146:
>> RuntimeWarning: overflow encountered in uint_scalars
>>   f('op-sub', 2, 110, lambda x, y: x - y, match_simple_binop,
>> [floats+vecs+mats+ints+ivecs+uints+uvecs,
>> floats+vecs+mats+ints+ivecs+uints+uvecs], template = '({0} - {1})')
>>
> 
> These are normal and nothing to be concerned about.  They happen because
> we're trying to test proper overflow behaviour of 32-bit uints in GLSL.  In
> order to generate the test vectors we have to overflow those values in
> Python, and Python warns when you do that.
> 
> If it's bugging you, we could probably rewrite the python code so that it
> does those computations without overflow (e.g. if y > x, instead of
> computing x - y, compute 2^32 + x - y).

The error messages did worry me that incorrect tests were possibly being
generated. But I'm not worried about it now.



More information about the Piglit mailing list