Age | Commit message (Collapse) | Author | Files | Lines |
|
Tested with libclc on a Radeon HD 7850.
Hex output values were generated via remainderf(float, float).
No implications as to the quality of the inputs is intended.
Signed-off-by: Aaron Watry <awatry@gmail.com>
Reviewed-by: Jan Vesely <jan.vesely@rutgers.edu>
|
|
cos(pi * 2k) = 1
Fixes cos test on beignet
Signed-off-by: Jan Vesely <jano.vesely@gmail.com>
|
|
Reviewed-by: Jan Vesely <jan.vesely@rutgers.edu>
|
|
v2: fixup python style(six.iteritems, itertools.product, enumerate, ...)
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
v2: "The size of each element in the mask must match the size of each element in the result."
v3: fixup python style (six. iteritems, enumerate, itertools.product, ...)
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
v2: simplify
mark local storage volatile
v3: python style
Passes on beignet(IVB), clover(carrizo, iceland), and intel CPU
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
v2: mark temporary storage as volatile
v3: python style
vstore_half requires workaround using short as local/private type
Tests pass on beignet(IVB), and intel CPU
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
|
|
Seriously, 100000000000 is not the only 64-bit integer. We should test
a few more of them.
These new integers trigger a bug in the GLSL IR int64 lowering code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
|
|
The extension requires a GL_ prefix, which the template didn't have.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Tested-by: Jason Ekstrand <jason@jlekstrand.net>
|
|
This typo causes some tests to be skipped that shouldn't.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
|
|
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
|
|
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
|
|
This adds 264 execution tests (all in the same directory, so will run quite
quickly with --process-isolation false) and 192 compiler tests.
Acked-by: Dave Airlie <airlied@redhat.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
This will be needed for the interaction of GL_ARB_gpu_shader_fp64 with
GL_ARB_gpu_shader_int64.
Acked-by: Dave Airlie <airlied@redhat.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Use generic names to reflect the upcoming dual use for 64-bit int types.
Acked-by: Dave Airlie <airlied@redhat.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Currently only 'd' for double, but will be extended for 64-bit integer
types.
Acked-by: Dave Airlie <airlied@redhat.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
We will extend it with int64 types.
Acked-by: Dave Airlie <airlied@redhat.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Plamena Manolova <plamena.manolova@intel.com>
|
|
This tests that the compiler accepts the new layout formats introduced by
NV_image_formats and also it's correct interaction with the
EXT_texture_norm16 specification.
v2: Only disallow normalized formats when EXT_texture_norm16 is not
available (Ilia)
v3: Shuffle the declaration as suggested to cover permutations of
NV_image_formats & EXT_texture_norm16 properly (Ilia)
Reorder imports (Dylan)
Add docstring description of the test (Dylan)
Other nits (Dylan)
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
This extensions is written against OpenGL ES 3.1 and 3.10 of the OpenGL ES
Shading Language specification.
v2: Fix missing 'GL_' prefix (Ilia)
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
|
|
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
The tests try to use target mem type aligned access.
Generated tests pass (except vstore-half which skips) on intel(cpu), beignet, nvidia CUDA
v2: Move code to main function, update copyright
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Acked-by: Tom Stellard <thomas.stellard@amd.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Executing code in the global scope that isn't in main isn't a
particularly good idea, but for our testing we call the main() function,
so moving this into main fixes the test, and it also improves the code
quality a bit.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
|
|
Currently there are a good number of files that aren't closed because
the call to the close function is in the wrong loop level. While moving
it in one level would solve the problem, using a context manager is
better style and ensures that the file is closed.
This error was spotted by py.test.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
|
|
This generator produces preprocessor defines tests, which are duplicated
by the gen_extensions_defined generator. It makes sense to me to let the
defines generator own this functionality (it's very minor anyway).
This also changes the version required in extensions defined to 130, per
the spec "OpenGL 3.0 and GLSL 1.30 are required."
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
|
|
This is a) good practice, b) fixes potential issues on windows, and c)
makes testing easier.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
|
|
This starts to fail with my upcoming patch to only expose extensions
based on shader version.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Before, in every drawing we were having the same VBO values per vertex
to be compared against the values in the uniforms. Now, we also have
different values per vertex so we can be sure that it is truly its own
data.
Signed-off-by: Andres Gomez <agomez@igalia.com>
Acked-by: Juan A. Suarez <jasuarez@igalia.com>
Acked-by: Dylan Baker <dylan@pnwbakers.com>
|
|
This fixes int64 failures.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
|
|
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
The dtype setting only works with numpy 1.9 and above, which doesn't
seem to be in most distros yet.
Reported-by: Jose Fonseca <jfonseca@vmware.com>
Tested-by: Jose Fonseca <jfonseca@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
|
|
Rather than forking this code further, I've just added support to the
standard generator for the 64-bit tests.
This relies on the shader_runner int64 support.
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
|
|
Added more test cases combinations by including u/byte and u/short GL
types in the VBO so the stride is smaller than a word.
Signed-off-by: Andres Gomez <agomez@igalia.com>
Acked-by: Alejandro Piñeiro <apinheiro@igalia.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
Signed-off-by: Andres Gomez <agomez@igalia.com>
Acked-by: Alejandro Piñeiro <apinheiro@igalia.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
This allows to set data of u/byte, u/short and half types for
attributes with the shader runner.
For example:
0/byte/int attname1/ushort/uint attname3/half/float
The syntax has been extended so the recommended way has replaced the
old COUNT field in the [vertex data] header line with the
corresponding GLSL type for the old TYPE field.
In any case, the extended syntax is backward compatible so it is still
possible to specify a vec3 attribute like:
attname/float/3
In addition to the now recommended format:
attname/float/vec3
Due to this, the arb_vertex_attrib_64bit input tests generator has
been also adapted to the new syntax.
Signed-off-by: Andres Gomez <agomez@igalia.com>
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
|
|
Because EmitVertex() will invalidate all previous output writes, we
need to set the value of the output variables for every vertex
Signed-off-by: Andres Gomez <agomez@igalia.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
|
|
Probably a wrong copy-paste. Trivial.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
|
|
This fixes the version requirement to be accurate, which prevents the
generator from producing bogus tests.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
|
|
This stops the generator from creating bogus tests.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
|
|
While this actually depends on 3.0 or ext_texture_array, this sets the
GLSL version requirement to 1.30, which is the GLSL version that
corresponds to GL 3.0.
This stops the generator from creating bogus tests.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
|
|
This spec actually wants 4.4, plus the other two ES compat extensions.
Mesa chooses to ignore this, so set it to 4.3 (which allows most mesa
drivers to test it.)
At the very least though this should be bumped to 3.2, since this
extension is never valid in a GL < 3.2 context.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
|
|
In order to emit a color for each vertex, we need to move fs_color
inside the loop because EmitVertex() will invalidate all previous
output writes, and there is an interpolated varying in the fragment
shader.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
This removes a significant amount of string parsing from both the module
and the templates, and simplifies some statements. The result is that
the generator is roughly 50% faster.
This string parsing comes from the rows and cols functions, which are
present in both the generator and the templates. Each of these functions
gets called roughly 40 million times. 40 million. The cols function in
particular accounts for nearly 20 seconds of runtime (and the rows about
5). The replacements account for about 1 second of runtime each, in
total.
When you consider that the runtime is about 70 seconds before this
patch, and about 35 after, that's another big win, probably enough that
it's not worth optimizing it further (if that's even really possible).
The remaining significant time sinks are the collections.deque (which is
called from within mako and is part of the python stdlib, thus we can't
optimize it) and the regular.shader_test.mako. While I can spot some
micro optimizations that might get us a few tenths of a second here and
there, I don't see anything that's going to win even a couple of seconds
except for maybe writing the list file from within the generator.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
This adds a new module with glsl type representations. The immediate
plan it to use these in the gen_vs_in_fp64 generator to reduce runtime
by removing the need for the cols and rows functions, which are
expensive.
These may be applicable to other generators, but those will have to
wait.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
This cuts the runtime for this generator by 3/4 on my system. That's 4
minutes to 1 minute. That's pretty impressive, and for both my system
and for our CI system this is a nice improvement. The generated files
are the same, minus whitespace changes (diff -NaurBw notes no
differences).
While I think the new template is more readable than the original code,
and it is definitely faster, it does introduce more code duplication
that could be cleaned up in a follow on patch.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
This rewrites the columns generator to use a single template rather than
the inherited template. The net result is that these tests are generated
in 1/3 of the time.
These are the minority tests from this generator. I measure that they
take about .3 seconds to generate (with this patch). So while this is
saving us a little bit of time, it's not going to make a big difference.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
Saves a little bit more runtime. It's not an extreme amount, but more
importantly is should save quite a bit of memory, which may help users
with memory-constraints.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
Don't build a list of filenames and print them after all of the tests
have run, act more like the other generators and print each name as the
test is generated. This both matches the behavior of the other
generators and also lowers runtime a bit
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|
|
This removes some overhead, and for me cuts the run time of this
generators from 4:16 to 4:03. It's not a lot, but it's something.
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
Reviewed-by: Andres Gomez <agomez@igalia.com>
|