summaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)AuthorFilesLines
2015-03-05all.py: Use TestProfile.group_manager default_args to set require_platformsDylan Baker1-175/+118
This allows the simplification of a large number of tests, reducing them to one argument, or at least reducing the number of lines that they occupy (or should occupy with reasonable line wrapping).
2015-03-05cl.py: Use flat list for program test dirsDylan Baker1-10/+11
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> TODO: tests this..
2015-03-05cl.py: simplify add_program_test_dirDylan Baker1-13/+4
This drops some nested functions, and makes a few calls simpler. TODO: Test this... Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05cl.py: Use TestProfile.group_managerDylan Baker1-99/+93
v2: - Fix function to work if run_concurrent is not set Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05sanity.py: Use TestProfile.group_managerDylan Baker1-2/+4
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05all.py: add asmparser tests automatically with loopDylan Baker1-443/+17
This works much like the shader_test and glsl parser test options, the difference being that rather than searching the whole tree only the directories with asmparser tests are searched. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05all.py: Convert all.py to use TestProfile.group_managerDylan Baker3-3219/+4233
This patch is massive, with a huge amount of churn, because it rewrites almost the entirety of all.py. It has to touch all of the helper functions as well. Of these I modified them appropriately or removed them. Criteria for removal was based on the complexity of the wrapper, and the frequency of use. Very simple functions or those used only a couple of times were removed. v2: - remove duplicate tests entries. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05all.py: move all of the helper functions to the top of the fileDylan Baker1-153/+149
This makes it a lot easier to read and work with all.py, which is still absolutely massive. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05all.py: use profile.test_list instead of profile.test for glean testsDylan Baker2-5/+14
These tests are already formated using grouptools, with no intermediate tree structures. Moving them to the flat test list reduces the amount of time spent migrating them to test_list before running tests. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05all.py: remove extra newline in list.Dylan Baker1-2/+1
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05arb_program_interface_query: Remove unused variable.Vinson Lee1-1/+1
Fix GCC unused-variable warning. resource-index.c: In function ‘piglit_init’: resource-index.c:211:23: warning: unused variable ‘i’ [-Wunused-variable] GLuint prog, shader, i; ^ Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-04shader_runner: fix uniform array name lookupsArthur Huillet1-7/+26
Don't look up uniform names for non-zero array elements, as this is illegal per GL4.5. >From the discussion of GetProgramResourceIndex in the GL4.5 spec: If name exactly matches the name string of one of the active resources for programInterface, the index of the matched resource is returned. Additionally, if name would exactly match the name string of an active resource if "[0]" were appended to name, the index of the matched resource is returned. Otherwise, name is considered not to be the name of an active resource, and INVALID_INDEX is returned. Note that if an interface enumerates a single active resource list entry for an array variable (e.g., "a[0]"), a name identifying any array element other than the first (e.g., "a[1]") is not considered to match. Instead, strip the "[xxx]" part of the name for the lookup. The NVIDIA proprietary driver enforces this rule of the specification, while Mesa is more permissive. Piglit shouldn't rely on the implementation being lax. Signed-off-by: Arthur Huillet <ahuillet@nvidia.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-04gl-1.0-readpixsanity: Fix Clang absolute-value warning.Vinson Lee1-1/+1
readpix.c:238:10: warning: using integer absolute value function 'abs' when argument is of floating point type [-Wabsolute-value] dd = abs(actual - expected); ^ readpix.c:238:10: note: use function 'fabs' instead dd = abs(actual - expected); ^~~ fabs Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-04arb_direct_state_access: Fix Clang absolute-value warning.Vinson Lee1-1/+1
getcompressedtextureimage.c:121:7: warning: using floating point absolute value function 'fabs' when argument is of integer type [-Wabsolute-value] if (fabs((int)data[i] - (int)expected[i]) > tolerance) { ^ getcompressedtextureimage.c:121:7: note: use function 'abs' instead if (fabs((int)data[i] - (int)expected[i]) > tolerance) { ^~~~ abs Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-04max-varyings: Use logical-OR instead of if statement to set failed.Matt Turner1-6/+4
By flattening the if statements we cut 213 instructions from the fragment shader (601 -> 388, or 35%), and we remove all register spilling on i965. Reduces runtime of "ext_transform_feedback-max-varyings" by -73.0547% +/- 0.682694% (n=27). Reviewed-by: Mark Janes <mark.a.janes@intel.com>
2015-03-04varying-packing: Use logical-OR instead of if statement to set failed.Matt Turner1-12/+5
By flattening the if statements we cut 288 instructions from the fragment shader (806 -> 518, or 35%), and we remove all register spilling on i965. Reduces runtime of "varying-packing-simple int separate" by -81.4453% +/- 0.255875% (n=483). Also consistently print 3 digits in the varying's names, to make reading/sorting simpler. Reviewed-by: Mark Janes <mark.a.janes@intel.com>
2015-03-04shaders: Add test for conditional mod propagation with different types.Matt Turner1-0/+37
The i965 driver has a pass that merges comparisons with zero into the instruction that generated the result. For example: add tmp x y cmp.ge.f0 null tmp 0.0 is optimized into add.ge.f0 tmp x y If the types of tmp are different in the add and cmp, comparisons against zero might not work the same. For instance if the addition is on unsigned integers, they may generate a result of 0x80000000 which is -0.0 reinterpreted as a float. I think this test triggers the same bug as this bug report. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89317 Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2015-03-04all.py: Fix two tests being assigned the same nameDylan Baker1-1/+1
commit 36b63cbbe7 fixed the execution of two tests, but didn't fix the fact that two tests are stored with the same name, thereby replacing the first with the second. This corrects that. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Acked-by: Laura Ekstrand <laura@jlekstrand.net> Reviewed-by: Martin Peres <martin.peres@linux.intel.com>
2015-03-04arb_program_interface_query: GetProgramResourceIndex testTapani Pälli3-0/+286
Test passes on Nvidia GTX 660 (binary driver version 331.38). v2: separate atomic counter index subtest (Ilia Mirkin) + code and shader cleanups + added subroutine index query test v3: fix indentation (argh!) Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03cl-program-tester: Avoid void pointer arithmetic.Jose Fonseca1-1/+1
Although CL tests are not built with MSVC, this is the single instance of void pointer arithmetic in them, so updating it to not use void pointer arithmetic will enable us to use -Werror=pointer-arith option universally in a follow on change. Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
2015-03-03arb_direct_state_access: Avoid void pointer arithmetic.Jose Fonseca1-2/+2
It's not supported by MSVC. Reviewed-by: Martin Peres <martin.peres@linux.intel.com>
2015-03-03arb_framebuffer_srgb/blit: Fix command line option 'disabled'Antia Puentes1-1/+1
To test the blit with FRAMEBUFFER_SRGB disabled, if the option 'disabled' was passed to the command line, was not being done. Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
2015-03-03arb_direct_state_access: Added *NamedRenderbuffer* testsMartin Peres3-0/+187
v2: review from Tapani - add some documentation - set the minimum GL version to 2.0 v3: - set the minimum GL version to 3.1 core (Ilia) - do some clean up at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: Added glCreateRenderbuffers testsMartin Peres3-0/+165
v2: - rename some subtests (Ian) v3: review from Tapani - add some documentation - set the minimum GL version to 2.0 v4: - set the minimum GL version to 3.1 core (Ilia) - do some clean up at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: Added glCreateSamplers testsMartin Peres3-0/+162
v2: - rename some subtests (Ian) v3: review from Tapani - add some documentation - set the minimum GL version to 2.0 v4: - set the minimum GL version to 3.1 core (Ilia) - do some clean up at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: Added glCreateProgramPipelines testsMartin Peres3-0/+160
v2: - rename some subtests (Ian) v3: review from Tapani - add some documentation - set the minimum GL version to 2.0 v4: review from Tapani - verify that the GL extension is present before testing it v5: - set the minimum GL version to 3.1 core (Ilia) - explicitly skip tests instead of silently skipping them - do some clean up at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: Added glCreateQueries testsMartin Peres3-0/+111
-v2: - rename some subtests (Ian) v3: review from Tapani - add some documentation - set the minimum GL version to 2.0 v4: - set the minimum GL version to 3.1 core (Ilia) - do some clean up at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: Added glGetTransformFeedback* testsMartin Peres3-0/+272
v2: review from Tapani - add the copyright for Intel - add some documentation - set the minimum GL version to 2.0 - use piglit_build_simple_program_unlinked Reviewed-by: Tapani Pälli <tapani.palli@intel.com> v3: - rewrite the test for GL 3.1 core (Ilia) - delete the copyright from vmware as none of the code is left - improve the cleanup at the end of the test Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-03arb_direct_state_access: Added glTransformFeedbackBufferRange testsMartin Peres3-0/+248
v2: review from Tapani - add the copyright for Intel - add some documentation - set the minimum GL version to 2.0 - use piglit_build_simple_program_unlinked Reviewed-by: Tapani Pälli <tapani.palli@intel.com> v3: - rewrite the test for GL 3.1 core (Ilia) - do not hardcode the tolerance (Laura) - delete the copyright from vmware as none of the code is left - improve the cleanup at the end of the test v4: - use the extern variable piglit_tolerance (Ilia & Laura) Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-03arb_direct_state_access: Added glTransformFeedbackBufferBase testsMartin Peres3-0/+236
v2: review from Tapani - add the copyright for Intel - add some documentation - set the minimum GL version to 2.0 - use piglit_build_simple_program_unlinked Reviewed-by: Tapani Pälli <tapani.palli@intel.com> v3: - rewrite the test for GL 3.1 core (Ilia) - do not hardcode the tolerance (Laura) - delete the copyright from vmware as none of the code is left - improve the cleanup at the end of the test v4: - use the extern variable piglit_tolerance (Ilia & Laura) Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-03dsa_create-transformfeedback: set the min. GL version to 3.1 coreMartin Peres1-1/+13
Also add the relevant quote from the spec. Signed-off-by: Martin Peres <martin.peres@linux.intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-03arb_direct_state_access: fix the execution of two testsMartin Peres1-2/+2
The problem was in all.py where the argument was not specified as an array but rather in the same string as the binary's path.. v2: Review from Ilia Mirkin - Get rid of some debugging left-overs - remove an extra space Signed-off-by: Martin Peres <martin.peres@linux.intel.com>
2015-03-02AMD_performance_monitor: add missing subtest resultSamuel Pitoiset1-0/+2
The "counters in range" subtest was not reported. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2015-03-02Don't use default texture objectAnuj Phogat1-0/+3
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-02Fix arguments count check and the test nameAnuj Phogat1-2/+2
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Laura Ekstrand <laura@jlekstrand.net>
2015-03-03arb_arrays_of_arrays: check array sizes when instance name differTimothy Arceri2-0/+74
Uniform interface blocks can have different instance names across shaders. These tests check that array rules are applied correctly. Test results: AMD Radeon HD 6670 - Catalyst 14.501.1003 OpenGL 4.4 uniform-block-array-instance-name-mismatch - pass uniform-block-array-size-and-instance-name-mismatch - fail Reviewed-by: Mark Janes <mark.a.janes@intel.com>
2015-03-03glsl-1.50: check array sizes when instance name differTimothy Arceri2-0/+64
Uniform interface blocks can have different instance names across shaders. These tests check that array rules are applied correctly. Test results: Intel Ivybridge - Mesa 10.6 uniform-block-array-instance-name-mismatch - pass uniform-block-array-size-and-instance-name-mismatch - pass AMD Radeon HD 6670 - Catalyst 14.501.1003 OpenGL 4.4 uniform-block-array-instance-name-mismatch - pass uniform-block-array-size-and-instance-name-mismatch - fail Reviewed-by: Mark Janes <mark.a.janes@intel.com>
2015-03-02arb_program_interface_query: add array to location testTapani Pälli1-7/+29
Patch adds array to GetProgramResourceLocation test and 3 subtests for invalid indexing of array. Case 2 fails on Nvidia GTX 660 (binary driver version 331.38). Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
2015-03-02arb_program_interface_query: change location test concurrentTapani Pälli1-1/+1
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
2015-02-27utils: Handle WM_QUIT properly.Jose Fonseca1-4/+17
We were never processing the WM_QUIT message, as GetMessage returns 0 in that case, and we were falling in an infinite loop. We also never see WM_CLOSE messages when pressing Alt-F4 or closing the window via the taskbar. We do however see WM_SYSCOMMAND::SC_CLOSE mesage. So handle that instead. With this change we always quit properly, regardless of the method (Escape/Alt-F4/Close window). Reviewed-by: Brian Paul <brianp@vmware.com>
2015-02-27utils: Don't intercept WM_KEYDOWN::VK_ESCAPE.Jose Fonseca1-7/+0
Instead pass through the escape char. user_keyboard_func or piglit_escape_exit_key will handle it already. Reviewed-by: Brian Paul <brianp@vmware.com>
2015-02-26util: Use posix_memalign for all non-Windows platforms.Vinson Lee1-3/+1
glibc < 2.16 does not have aligned_alloc. Suggested-by: Jose Fonseca <jfonseca@vmware.com> Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
2015-02-26util: Define C99 __func__ macro on MSVC.Jose Fonseca1-0/+4
MSVC, including 2013, only supports __FUNCTION__ -- https://msdn.microsoft.com/en-us/library/b0084kay.aspx Trivial.
2015-02-26arb_program_interface_query: GetProgramResourceLocation testTapani Pälli5-0/+451
All tests pass on Nvidia GTX 660 (binary driver version 331.38). GetProgramResourceLocationIndex will be covered by a separate test. v2: - separate subroutine and compute enums and test only when extensions are available. - add some more inputs and outputs - add validation against old matching API functions v3: - rebasing all.py format changes, indent cleanup - no need to require GL_EXT_geometry_shader4 (Ilia Mirkin) Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
2015-02-25utils: Write event loop for Waffle+WGL.Jose Fonseca1-8/+64
Without this it is not really possible to see test rendering interactively. Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2015-02-24Revert "cl tests: move non-generated tests out of the generated tests dir"Dylan Baker3-37/+0
This reverts commit ff8898df3c78324b2d8945c855a9d2e0034f5525. This broke cl tests, and it's a very trivial self contained patch, so we'll just revert it. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> reported-by: Michel Dänzer <michel@daenzer.net>
2015-02-24getteximage-luminance: remove obsolete piglit_dispatch_default_init() callEmil Velikov1-1/+1
By the time piglit_init() is executed, the context is creates and the dispatch table has been initialised. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com>
2015-02-24Revert "ext_timer_query: the timestamp test does not require the EXT extension"Emil Velikov1-2/+2
This reverts commit 380e1e5ddd809f6a2870aedd70e1f369e44f2f85. Unintentionally commited the wrong patch.
2015-02-24ext_timer_query: the timestamp test does not require the EXT extensionEmil Velikov1-2/+2
The test itself is written against the ARB extension, and neither the test or the ARB extension requires the EXT one. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com>
2015-02-23all.py: replace import_glsl_parser_test with loop searchDylan Baker1-140/+25
This finds the following additional tests: spec/arb_seperate_shader_objects/compiler/1.10/layout-location.frag spec/arb_seperate_shader_objects/compiler/1.10/layout-location.vert spec/arb_seperate_shader_objects/compiler/1.20/layout-location.frag spec/arb_seperate_shader_objects/compiler/1.20/layout-location.vert spec/arb_seperate_shader_objects/compiler/1.30/layout-location.frag spec/arb_seperate_shader_objects/compiler/1.30/layout-location.vert spec/arb_seperate_shader_objects/compiler/1.40/layout-location.frag spec/arb_seperate_shader_objects/compiler/1.40/layout-location.vert spec/arb_seperate_shader_objects/compiler/1.50/layout-location.frag spec/arb_seperate_shader_objects/compiler/1.50/layout-location.vert spec/arb_seperate_shader_objects/compiler/1.50/layout-location.geom spec/arb_seperate_shader_objects/compiler/1.50/layout-location.geom fails on my Ivybridge This also needs to be merged back into the previous two commits to create a clean, linear history with no regressions. Fore review purposes it makes sense not to merge them. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>