summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-10-07framework: Split FastSkipMixin.Dylan Baker2-123/+251
This splits the FastSkipMixin into two classes. One that actually does the fast skipping, and one that provides a mixin for Test. This split will allow the class to be used in the traditional way, but also in shader_test.MultiShaderTest. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-07framework: Split the file parsing code out of ShaderTestDylan Baker1-38/+68
This is both nicer since it provides better code quality (a separation of roles), and because it's going to make writing a shader_test class that can do N:1 tests much easier. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-07framework/results: Lower subtest namesDylan Baker1-3/+3
This makes the behavior of the Subtests class more like that of the TestDict class, and fixes a bug in MultiShaderRunner, which will be added in a subsequent patch in this series. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-05framework: Fix verbose loggerDylan Baker2-0/+7
Which was broken by the last commit touching the logger, as were several unittests that continued passing because of a dirty environment. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-05framework/log: Don't add tests to running list until they actually startDylan Baker1-2/+4
Otherwise there will be a spinner in the final call to summary that's printed when piglit finishes. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-05framework: If exiting a run, ensure that the status is readableDylan Baker1-13/+21
This patch catches C-c, and any Exception while tests are running, prints the status again with a newline, and then raises the exception. This makes the output visible even when a stacktrace is printed. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-10-05arb_compute_variable_group_size: check for invalid work group countSamuel Pitoiset1-0/+32
This test passes with NVIDIA blob. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-10-04arb_program_interface_query: Silence return-type warning.Vinson Lee1-0/+1
compare-with-shader-subroutine.c: In function 'get_shadertype_from_program_interface': compare-with-shader-subroutine.c:251:1: warning: control reaches end of non-void function [-Wreturn-type] } ^ Fixes: 39ccf8c59bd5 ("arb_program_interface_query: add compare-with-shader-subroutine test") Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-10-04Add glsl-1.30/execution/fs-loop-cont-else-bugNicolai Hähnle1-0/+44
This is a regression test for a very specific compiler bug in radeonsi. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97887 Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
2016-10-03tests: fix unused variable in gles versions of arb_viewport_array/queriesDylan Baker1-0/+2
tests/spec/arb_viewport_array/queries.c: In function ‘piglit_init’: tests/spec/arb_viewport_array/queries.c:58:11: warning: unused variable ‘vald’ GLdouble vald[4] = {0.0, 0.0, 0.0, 0.0}; Which is only used if compiled with OpenGL support, but not when compiled for GLES. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Reviewed-by: Vinson Lee <vlee@freedesktop.org>
2016-10-03tests: remove unused variable from ext_image_dma_buf_import/refcountDylan Baker1-1/+0
tests/spec/ext_image_dma_buf_import/refcount.c:59:6: warning: unused variable ‘cpp’ int cpp = 4; ^~~ Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Reviewed-by: Vinson Lee <vlee@freedesktop.org>
2016-10-03utils: Move DRM_FORMATS defines to piglit_drm_dma_buf.h.Vinson Lee2-15/+17
This patch fixes this build error. transcode-nv12-as-r8-gr88.c: In function ‘create_textures’: transcode-nv12-as-r8-gr88.c:178:7: error: ‘DRM_FORMAT_R8’ undeclared (first use in this function) DRM_FORMAT_R8, r8_pixels); ^ Fixes: 0222f5db00fd ("dmabuf: fix YUV tests for drivers other than intel") Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97951 Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
2016-09-29add ARB_compute_variable_group_size testsSamuel Pitoiset15-0/+842
v3: - enforce local-size.c test (Nicolai) - add mixed_variable_fixed_local_work_size.comp (Nicolai) v2: - update formatting spec quotations (Nicolai) - use shader_runner for the basic test (Ian) - add a new test which checks various local sizes (Nicolai) Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-09-29shader_runner: add support for glDispatchComputeGroupSizeARB()Samuel Pitoiset1-0/+7
This allows to dispatch compute shaders with a variable local size using the new "compute group size" command. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-09-29utils: define DRM_FORMATS needed by dma_buf testsDylan Baker2-12/+15
If they're not defined by the installed libdrm already. This moves code already defined in transcode-nv12-as-r8-gr88 to the utils level, so that all tests that require these formats get them, and also adds on additional define that wasn't in the mentioned test. bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97951 Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Tested-by: Vinson Lee <vlee@freedesktop.org>
2016-09-29vs-loop-zero-iterations-two-exits2: Use green for pass, red for fail.Eric Anholt1-4/+4
This test was the opposite of standard piglit style, which was a surprise. Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-09-29vs-loop-zero-iterations-two-exits2: Fix on Mesa.Eric Anholt1-1/+3
Mesa eliminates the loop and therefore the loop_count uniform, which causes shader_runner to report failure when it tries to set it. Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-09-26dmabuf: fix YUV tests for drivers other than intelRob Clark18-218/+314
Ok, so the basic problem with the YUV tests is that they currently completely ignore driver/hw pitch requirements, since the code that allocates the buffer doesn't know the pixel format, only the 'cpp'. The yuv test creates a small 4x4 yuv eglimage. If, say, the hardware requires the pitch to be aligned to, say, 32pixels, everything is fine for the Y plane, but the subsampled U/V or U+V plane has half as many pixels. (This did help me catch a bug in driver, not rejecting the dmabuf import with invalid pitch, but that doesn't help to get the piglit tests running.) The best approach I could come up with to fix this is to pass the fourcc all the way down to the code that creates the dmabuf (and copies src data into the dmabuf). Unfortunately this makes the patch a bit bigger than I was hoping, and not really sure a good way to split it up. This is tested on i965 (with the intel dma-buf backend) and freedreno (with the gbm dma-buf backend). In the gbm case, it requires new gbm format values for R8 and GR88, which is on mesa master as of this morning. (So I bumped the gbm version dependency to 12.1.) Signed-off-by: Rob Clark <robdclark@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2016-09-26xts: Put the XTS results files in the piglit results directory.Eric Anholt1-5/+21
Fixes races in the X Server's make check environment, which runs multiple "piglit-run.py -t xts" in parallel and would have the two runs overwriting each other's logs in between execution and parsing. Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-09-23oes_viewport_array: add copies of relevant arb_fragment_layer_viewport testsIlia Mirkin3-0/+204
Adapted for GL ES. Note that if GS does not write a viewport index (or there is none), the value of gl_ViewportIndex is undefined, unlike in desktop GL. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Acked-by: Kenneth Graunke <kenneth@whitecape.org>
2016-09-23shader_runner: use a byte type so that the texture isn't created as floatIlia Mirkin1-1/+1
Mesa decides to create it as a float texture (since it's an unsized internal format), but then it can't be rendered to in ES (without having been created via a sized internal format). To facilitate matters, just use GL_UNSIGNED_BYTE, since we really don't care about the format here. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Acked-by: Kenneth Graunke <kenneth@whitecape.org>
2016-09-23cmake: Require egl 11.0.Vinson Lee1-1/+1
mesa 11.0 is needed for EGLDeviceEXT symbol. egl_ext_device_query.c: In function ‘main’: egl_ext_device_query.c:33:2: error: unknown type name ‘EGLDeviceEXT’ EGLDeviceEXT device = EGL_NO_DEVICE_EXT; ^ Signed-off-by: Vinson Lee <vlee@freedesktop.org>
2016-09-22arb_query_buffer_object: beef up the testNicolai Hähnle3-115/+186
A bunch of additions to the ARB_query_buffer_object test: 1. test different result types (including 64 bit types) 2. compare the written result with equality to the result obtained by querying on the CPU 3. add an additional mode to catch cache invalidation problems 4. additional checks that no values are written when they shouldn't 5. proper extension checks for the different query types Also, rename the binary for the test to fit the extension-testname pattern. Acked-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-09-21arb_texture_view: adapt a few more tests to work with OES_texture_viewIlia Mirkin6-31/+102
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-09-21arb_texture_view: convert sampling-2d-array-* to GLES compatibilityIlia Mirkin5-74/+129
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-09-21arb_texture_view: convert remainder of rendering_* to work with GLESIlia Mirkin6-96/+187
These tests used a mix of GL 1.x and newer functionality. This switches all of them up to require GL 3.0 to avoid annoyance. All hardware that can support texture views is GL 3.0-capable. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-09-21arb_texture_view: start converting for GL_OES_texture_view friendlinessIlia Mirkin3-162/+482
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-09-21arb_viewport_array: rework tests to work with GL_OES_viewport_arrayIlia Mirkin14-95/+288
This makes some fairly simple changes to the existing tests to also work with GL_OES_viewport_array, which presents largely identical functionality. All of the tests continue to pass with desktop GL, and also work with my soon-to-be-posted GL ES implementation for mesa. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-09-18arb_texture_view/rendering-formats: test glClear(1, 1, 1, 1) w/ texture viewsMarek Olšák1-11/+559
needed to exercise radeonsi codepaths
2016-09-17Fix "glCear" typo.Kenneth Graunke1-1/+1
2016-09-16framework: Make driver_classifier convert to str (unicode)Dylan Baker1-2/+2
In python2 the code as is works, although there might be odd corners. In python 3 it fails because the code tries to match bytes and strs, which doesn't work at all. This patch fixes the issue by converting the output from bytes to str (unicode) immediately, so we don't have to think about it again. Reported-by: Dan Kegel <dank@kegel.com> Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-16unittests: Add test for DriverClassifier.get_glxinfoDylan Baker1-0/+25
Ensure that it converts bytes to str and also collects correctly. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-16framework/driver_classifier: import errnoDylan Baker1-0/+1
Since it's being used. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-16gl-1.3-alpha_to_coverage_nop: new test of no-op GL_SAMPLE_ALPHA_TO_COVERAGEBrian Paul5-0/+126
Currently fails with llvmpipe. Fragments with alpha <= 0.5 are discarded. Passes with softpipe, NVIDIA driver. v2: test with GL_MULTISAMPLE both enabled and disabled, fix all.py entry Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
2016-09-16arb_framebuffer_srgb-srgb_pbo: New arb_framebuffer_srgb test.Neha Bhende3-0/+253
This tests the effect of PBO operation when GL_FRAMEBUFFER_SRGB is enabled. Passes with Mesa, fails with NVIDIA. VMware bug 1426768 Reviewed-by: Brian Paul <brianp@vmware.com>
2016-09-16all.py: Test any apitraces we find under tests/apitrace/traces.Eric Anholt2-1/+22
See https://github.com/anholt/trace-db for a repository of traces and their references images. v2: Add a note about were to find some traces to put in here. Reviewed-by: Dylan Baker <dylan@pnwbakers.com> (v1)
2016-09-16apitrace: Add a script for capturing and comparing trace images.Eric Anholt1-0/+149
v2: Apply feedback from Dylan Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
2016-09-16framework: Add a driver classifier based on the renderer string.Eric Anholt2-0/+181
For the apitrace test runner, I need to be able to store known-good images for various drivers, which means I need some way to group drivers. Not all Mesa drivers we care about are covered here, but this is a sample to get things started. v2: Apply feedback from Dylan, add classification for my Skylake. Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
2016-09-16glsl-1.10: complex loop unrolling testsTimothy Arceri3-0/+148
These test so called complex loop unrolling in Mesa which just means unrolling a loop with two exits where the trip count is only known for one of the exits. Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-09-15Mark timer tests as not concurrentNicolai Hähnle1-3/+3
This reduces the chance of false positives caused by system load: On an 8-core test machine with an AMD Polaris, I've observed about a 50% false positive rate on these tests when running concurrently. On the same system, I have not observed a single failure in 10 runs when running non-concurrently.
2016-09-10cl: Initialize errNo on invalid image type (v2).Vinson Lee1-0/+1
Fixes sometimes-uninitialized warning. piglit-util-cl.c:1052:13: warning: variable 'errNo' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] } else if (desc->image_type == CL_MEM_OBJECT_IMAGE3D) { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ piglit-util-cl.c:1062:28: note: uninitialized use occurs here if(!piglit_cl_check_error(errNo, CL_SUCCESS)) { ^~~~~ piglit-util-cl.c:1052:9: note: remove the 'if' if its condition is always true } else if (desc->image_type == CL_MEM_OBJECT_IMAGE3D) { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ piglit-util-cl.c:1040:14: note: initialize the variable 'errNo' to silence this warning cl_int errNo; ^ = 0 Fixes: 910cd6c222930 ("cl: add image and sampler utility functions") Signed-off-by: Vinson Lee <vlee@freedesktop.org> Acked-by: Jan Vesely <jan.vesely@rutgers.edu> Reviewed-by: Serge Martin <edb+piglit@sigluy.net>
2016-09-10Revert "cl: Initialize errNo on invalid image type."Serge Martin1-1/+0
This reverts commit 5b037e06730fb4d219c3e5f374ad96594e10e3b1. Sorry I pushed the wrong version.
2016-09-10cl: Initialize errNo on invalid image type.Vinson Lee1-0/+1
Fixes sometimes-uninitialized warning. piglit-util-cl.c:1052:13: warning: variable 'errNo' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] } else if (desc->image_type == CL_MEM_OBJECT_IMAGE3D) { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ piglit-util-cl.c:1062:28: note: uninitialized use occurs here if(!piglit_cl_check_error(errNo, CL_SUCCESS)) { ^~~~~ piglit-util-cl.c:1052:9: note: remove the 'if' if its condition is always true } else if (desc->image_type == CL_MEM_OBJECT_IMAGE3D) { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ piglit-util-cl.c:1040:14: note: initialize the variable 'errNo' to silence this warning cl_int errNo; ^ = 0 Fixes: 910cd6c222930 ("cl: add image and sampler utility functions") Signed-off-by: Vinson Lee <vlee@freedesktop.org> Acked-by: Jan Vesely <jan.vesely@rutgers.edu> Reviewed-by: Serge Martin <edb+piglit@sigluy.net>
2016-09-09tox: add a streams target.Dylan Baker3-10/+12
Also enables the target in travis and appveyor. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-09framework: Add support for jsonstreamsDylan Baker2-34/+79
This commit adds support in the json backend for using an external library that I wrote called jsonstreams. It's a pretty self-explanatory library, and for piglit has several advantages. First, I've measured a consistent 10-15 second speed up for running the quick profile. Second, it *vastly* reduces the amount of memory piglit needs to write the final JSON document out. This is not implemented as a separate backend because the way that piglit's backend are implemented only one backend can handle a specific file extension. While this can be worked around by setting the extension to something like '.junit.xml' that doesn't really make sense here, since they are writing the same format, just using different means. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-09unittests: Fix JSON schema test to pass time_elapsedDylan Baker1-1/+2
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-09unittests: Fix shared data for backends.Dylan Baker1-2/+5
It turns out that the backends coincidently put certain fields in, but the new jsonstreams backend does not automatically add these fields, it must be passed them. (This is the behavior of piglit when not testing). Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-09unittests: don't require totals section in schemaDylan Baker1-1/+1
We generate this on the fly if it's not there and add it. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2016-09-08tests/llvmpipe: Disable gl-1.0-blend-funcAdam Jackson1-0/+1
Takes over 40 minutes and 16GB on Skylake. Most of the blend functionality in llvmpipe is adequately covered by Mesa's in-tree tests anyway. Signed-off-by: Adam Jackson <ajax@redhat.com>
2016-09-08egl-nok-swap-region: Fix build against new eglext.hAdam Jackson1-2/+3
New eglext.h has the function pointer typedef corrected to end in PROC like everything else. We'd like to build against both old and new headers (at least for a while), while using the idiomatic PROC name in the actual code. To do this, before including any headers, tell the preprocessor to substitute the ...PROC string for any ...NOK string it encounters. Against old headers this will correct the typedef to the standard form; against new headers, it will do nothing. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>