Test dependency hints on exp2 instructions.

Reviewed-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Mike Stroyan <mike@lunarg.com>
framework: fix comparing NOTRUN/SKIP to other statuses

The current logic causes transitions involving notrun/skip to not show
up in problems. It also encodes display decisions in lt/gt/etc
operators. This change adjusts the status class to be logically simpler
by removing the special handling of lt/gt/etc so that max(status) can
work, and reorders the logic that figures out which category to select.

Tests are updated to encode the new order -- notrun/skip are now
comparable to (and less than) the other statuses, but are unordered
between one another.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dylan Baker <baker.dylan.c@gmail.com>
framework: fix status order so that having dmesg is worse than not

It seems completely wrong to mark a test as "fixed" if you start
emitting dmesg spam in the middle of it. However it is a fix, of sorts,
to go from a dmesg-fail to a plain fail. Fix the result order to match
these expectations.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dylan Baker <baker.dylan.c@gmail.com>
piglit-summary-html.py: Fix regression from constant conversion

This fixes a regression introduced in ec37e0fa951

If piglit-summary-html.py is run with -e all it will except. This is
because I missed converting the various statuses to constants from
classes

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Add new constant to status with all statuses

This patch adds an authoritative list of statuses in one place as a
tuple. This is left as a tuple since a tuple is immutable, but is still
ordered. This list is ranked from best to worse (with skip and notrun at
the end).

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
python: replace testBinDir with TEST_BIN_DIR

From python's PEP8:

 "Constants are usually defined on a module level and written in all
 capital letters with underscores separating words. Examples include
 MAX_OVERFLOW and TOTAL."

This patch generated with the following shell command:
'find . -name '*py' | xargs sed -i -e 's!testBinDir!TEST_BIN_DIR!g'

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
python: replace Test argument runConcurrent with run_concurrent

From python's PEP8:

 "Function names should be lowercase, with words separated by
 underscores as necessary to improve readability."

This patch was generated with the following shell command:
find . -name '*py' | xargs sed -i -e 's!runConcurrent!run_concurrent!g'

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
python: replace Test.interpretResult with Test.interpret_result

From python's PEP8:

 "Function names should be lowercase, with words separated by
 underscores as necessary to improve readability."

This patch was generated with the following shell command:
find . -name '*py' | xargs sed -i -e 's!interpretResult!interpret_result!g'

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
framework/exectest.py: remove deprecated builtin use

Upstream python considers map() and filter() deprecated in favor of
using comprehensions. These comprehensions are easier to read, and can
act as both a map and a filter at the same time. In this case we are
using generator comprehensions, which have an additional advantage of
lower memory consumption.

v2: - minor readability improvements

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
framework/exectest.py: fix check_for_skip_scenario

This makes a couple of changes. First it removes Test.skip_test, which
was set equal to Test.check_for_skip_scenario(). Second, it removes the
unused command argument from check_for_skip_scenario's signature.
Finally it implements a no-op version in Test, and moves the version in
Test to PiglitTest, since it is a native piglit test specific check.

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
framework/exectest.py: Do unicode conversion in get_command_result()

This patch moves the unicode conversion out of run and into
get_command_result. Since this is meant to fix the python2
unicode/bytestring madness it makes more sense to do this earlier rather
than later.

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
framework/exectest.py: use grouping parens instead of \ to break strings

v2: - don't call the same function multiple times

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
framework/exectest.py: remove Test.split_test

This attribute was used exclusively by
PiglitTest.check_for_skip_scenario(), so just making it a local variable
of that function makes far more sense than making it a Test instance
attribute

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Add a piglit test which reproduces an opt_vectorizer bug.

This reproduces an ir_validator failure in Serious Sam 3 shaders caused
by the vectorizer pass, which I uncovered while doing unrelated work.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Matt Turner <mattst88@gmail.com>
framework: Fix concurrency regression introduced by Test refactor

For whatever reason the concurrency flag was not passed to
GLSLParserTest and ShaderTest after the refactor. This patch fixes that
by always passing that keyword argument as was done before.

Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
arb_gpu_shader5: Test some more `sample` qualifier cases.

Mesa has been allowing `sample` (and `centroid`) in a bunch of places
where they are not valid. These tests exercise a few more interesting
cases.

Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
gl-3.0: Fix required-sized-texture-formats for depth formats

When a sized internal depth format is requested, implementations are allowed
to choose a format as closely as possible (whose definition is up to the
implementations) on GL 3.0.

Thanks to Kenneth Graunke for pointing this out.

Signed-off-by: Chia-I Wu <olv@lunarg.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
ext_image_dma_buf_import/intel_external_sampler_only: fix link error

Mesa is no longer exporting the symbols of OES_framebuffer_object,
which caused a link error with this test.

In addition, the test needed additional extension checks.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=77295
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Tested-by: Dylan Baker <baker.dylan.c@gmail.com>
remove executable bits from C files.
Yet another fix of the FSF address (i.e., don’t use it at all).

Signed-off-by: Matěj Cepl <mcepl@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>