Re: [Piglit] [PATCH 8/9] framework/exectest.py: use grouping parens instead of \ to break strings

2014-04-10 Thread Dylan Baker
On Wednesday, April 09, 2014 23:01:24 Ilia Mirkin wrote: On Wed, Apr 9, 2014 at 10:56 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Wednesday, April 09, 2014 09:58:47 PM Ilia Mirkin wrote: On Wed, Apr 9, 2014 at 9:27 PM, Dylan Baker baker.dyla...@gmail.com wrote: --- framework

Re: [Piglit] [REGRESSION] runtime of gpu.py doubled by commit 26326d4032631cdb4eb6816aada6c81db6f186d7

2014-04-11 Thread Dylan Baker
this to: 26326d4032631cdb4eb6816aada6c81db6f186d7 is the first bad commit commit 26326d4032631cdb4eb6816aada6c81db6f186d7 Author: Dylan Baker baker.dyla...@gmail.com Date: Wed Feb 5 15:44:37 2014 -0800 framework/shader_test.py: simplify ShaderTest This is on an A10-7850K (quad core Kaveri) APU FWIW. I believe that I have found

[Piglit] [PATCH 1/2] cmake: Use piglit_add_executable instead of add_executable

2014-04-11 Thread Dylan Baker
Using add_executable prevents the compiled binary from being installed when installing out of tree. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- tests/spec/arb_compute_shader/CMakeLists.gl.txt| 4 +- .../arb_compute_shader/compiler/CMakeLists.gl.txt | 2

[Piglit] [PATCH 2/2] cmake: buld cl with piglit_add_executable insead of add_executable

2014-04-11 Thread Dylan Baker
piglit_add_executable is used to actually install the final binary. Without it the final binaries wont be installed with make install. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- tests/cl/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/cl

Re: [Piglit] [PATCH] ext_image_dma_buf_import/intel_external_sampler_only: fix link error

2014-04-13 Thread Dylan Baker
Signed-off-by: Jordan Justen jordan.l.jus...@intel.com Cc: Ian Romanick i...@freedesktop.org Cc: Dylan Baker baker.dyla...@gmail.com --- .../intel_external_sampler_only.c | 26 +++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/tests/spec

Re: [Piglit] [REGRESSION] runtime of gpu.py doubled by commit 26326d4032631cdb4eb6816aada6c81db6f186d7

2014-04-14 Thread Dylan Baker
On Monday, April 14, 2014 05:16:56 PM Michel Dänzer wrote: On 12.04.2014 04:35, Dylan Baker wrote: On Tuesday, April 08, 2014 18:42:47 Michel Dänzer wrote: I was away for the last two weeks, and when I came back I noticed that gpu.py is now taking around 20 minutes to complete, whereas

Re: [Piglit] [PATCH 1/3] framework.log: Replace synchronized_self decorator

2014-04-15 Thread Dylan Baker
On Tuesday, April 08, 2014 14:39:08 Dylan Baker wrote: This replaces the synchronized_self decorator from piglit's threads module with a context manager (with foo: stuff). This is more standard python, and means having a little less hand rolled code around. Signed-off-by: Dylan Baker

[Piglit] [PATCH 03/13] exectest: Don't pass env to Test.run()

2014-04-15 Thread Dylan Baker
This makes env a Test class attribute. This allows Test and all of it's children to use env without passing it around, which saves a lot of passing, and allows some more code cleanups and re-factors. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 18

[Piglit] [PATCH 09/13] framework/exectest.py: Replace toplevel if in Test.run() with assertion

2014-04-15 Thread Dylan Baker
this is probably a python problem not a test problem it makes more sense to assert and draw attention to a python bug. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 119 -- 1 file changed, 57 insertions(+), 62 deletions(-) diff

[Piglit] [PATCH 08/13] framework/exectest.py: simplify gnome bug loop

2014-04-15 Thread Dylan Baker
This uses a for loop instead of an incrementing while loop. This might be slightly faster since xrange() doesn't do arithmetic, but the big advantage is less code and it's easier to read. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 9 ++--- 1 file changed

[Piglit] [PATCH 02/13] framework: Split TestProfile and related out of core

2014-04-15 Thread Dylan Baker
This solves a dependency loop between core and exectest, laying the groundwork for future improvements to the exectest module. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/core.py| 181 framework/profile.py | 219

[Piglit] [PATCH 11/13] framework/exectest.py: Test.execute() remove if's that are constant

2014-04-15 Thread Dylan Baker
There are a couple of if checks in Test.execute() that will always have the same truth value. Remove completely the ones that are always false, and unconditionally run the ones that are true. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 9 + 1 file

[Piglit] [PATCH 05/13] framework/exectest.py: Don't pass redundant args to Test.Get_command_result()

2014-04-15 Thread Dylan Baker
This puts fullenv in Test.get_command_result() (since that's the only place it's actually used). Also don't pass self.command as an argument (with an additional assignment). Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 16 ++-- 1 file changed, 6

[Piglit] [PATCH 10/13] framework: stop passing duplicate arguments

2014-04-15 Thread Dylan Baker
attribute. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 129 ++--- framework/gleantest.py | 14 ++-- framework/tests/gleantest_tests.py | 5 +- tests/es3conform.py| 9 ++- tests/igt.py

[Piglit] [PATCH 04/13] framework/exectest.py: Move valgrind to Test.command property

2014-04-15 Thread Dylan Baker
Since ENV is now available to all of Test we can set the valgrind command in the command property, which is where it makes the most sense to have it. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 7 +++ framework/gleantest.py | 2 +- 2 files changed, 4

[Piglit] [PATCH 12/13] framework/exectest.py: optimize 'fail' if not result

2014-04-15 Thread Dylan Baker
There are several checks that look for the 'result' in self._result and set it to fail if it's not there. Let's just make the default value of 'result' 'fail' and get rid of all of these checks. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 7 +-- 1 file

[Piglit] [PATCH 07/13] framework/exectest.py: Fix action for non 0 returncode

2014-04-15 Thread Dylan Baker
Previously a test would be marked with a note if the returncode was non-zero. This isn't very useful as no one looks at the note field. Instead, this patch marks tests that pass and return a non-zero status as warn, so a developer will actually see that. Signed-off-by: Dylan Baker baker.dyla

[Piglit] [PATCH 13/13] exectest.py: remove try/except from PiglitTest.interpret_result

2014-04-15 Thread Dylan Baker
This removes a try/except that would catch everything and return a 'fail' status and a possible related error message. Instead, just let the method except and allow it to get caught and logged as a python exception. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py

[Piglit] More exectest cleanups and refactors

2014-04-15 Thread Dylan Baker
This series offers additional cleanup, re-factors and optimizations to the Test class. This series puts a lot of work into Test.run() and Test.execute(), with a focus on reducing overall code, specifically function calls, combining if trees, and replacing slow with generators or comprehensions.

[Piglit] [PATCH 06/13] framework/exectest.py: Optimize skips in Test.run()

2014-04-15 Thread Dylan Baker
This optimizes the Test.check_for_skip_scenario() path. With this change there is a single if branch for skip, and a single alternate path for non-skip. Skip returns early, bypassing a bunch of processing overhead that is unnecessary. Signed-off-by: Dylan Baker baker.dyla...@gmail.com

Re: [Piglit] [PATCH 05/13] framework/exectest.py: Don't pass redundant args to Test.Get_command_result()

2014-04-16 Thread Dylan Baker
On Tuesday, April 15, 2014 19:37:48 Ilia Mirkin wrote: On Tue, Apr 15, 2014 at 7:12 PM, Dylan Baker baker.dyla...@gmail.com wrote: This puts fullenv in Test.get_command_result() (since that's the only place it's actually used). Also don't pass self.command as an argument (with an additional

Re: [Piglit] [PATCH 08/13] framework/exectest.py: simplify gnome bug loop

2014-04-16 Thread Dylan Baker
On Tuesday, April 15, 2014 20:07:00 Ilia Mirkin wrote: On Tue, Apr 15, 2014 at 7:12 PM, Dylan Baker baker.dyla...@gmail.com wrote: This uses a for loop instead of an incrementing while loop. This might be slightly faster since xrange() doesn't do arithmetic, but the big advantage is less

[Piglit] [Patch v2 03/13] framework/exectest.py: Replace if with assert in Test

2014-04-16 Thread Dylan Baker
back to python and not to a specific test. v2: - Replace a similar patch that was later in the series with this Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 143 -- 1 file changed, 69 insertions(+), 74 deletions

[Piglit] More exectest cleanups and refactors v2

2014-04-16 Thread Dylan Baker
This is largely the same as the previous version, but with changes suggested by Ilia incorperated, and a replacment of v1 patch 9 with v2 patch 3. This results in a net change of 4 lines from v1 by patch 13, with three of those being comments, and the remaining change that an assert was moved from

[Piglit] [Patch v2 05/13] framework/exectest.py: Move valgrind to Test.command property

2014-04-16 Thread Dylan Baker
Since ENV is now available to all of Test we can set the valgrind command in the command property, which is where it makes the most sense to have it. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 7 +++ framework/gleantest.py | 2 +- 2 files changed, 4

[Piglit] [Patch v2 02/13] framework: Split TestProfile and related out of core

2014-04-16 Thread Dylan Baker
This solves a dependency loop between core and exectest, laying the groundwork for future improvements to the exectest module. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/core.py| 181 framework/profile.py | 219

[Piglit] [Patch v2 04/13] exectest: Don't pass env to Test.run()

2014-04-16 Thread Dylan Baker
This makes env a Test class attribute. This allows Test and all of its children to use env without passing it around, which saves a lot of passing, and allows some more code cleanups and re-factors. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 18

[Piglit] [Patch v2 11/13] framework/exectest.py: Test.execute() remove if's that are constant

2014-04-16 Thread Dylan Baker
There are a couple of if checks in Test.execute() that will always have the same truth value. Remove completely the ones that are always false, and unconditionally run the ones that are true. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 9 + 1 file

[Piglit] [Patch v2 08/13] framework/exectest.py: Fix action for non 0 returncode

2014-04-16 Thread Dylan Baker
Previously a test would be marked with a note if the returncode was non-zero. This isn't very useful as no one looks at the note field. Instead, this patch marks tests that pass and return a non-zero status as warn, so a developer will actually see that. Signed-off-by: Dylan Baker baker.dyla

[Piglit] [Patch v2 09/13] framework/exectest.py: simplify gnome bug loop

2014-04-16 Thread Dylan Baker
This uses a for loop instead of an incrementing while loop. This might be slightly faster since xrange() doesn't do arithmetic, but the big advantage is less code and it's easier to read. v2: - use 'x in str' instead of str.find() Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework

[Piglit] [Patch v2 12/13] framework/exectest.py: optimize 'fail' if not result

2014-04-16 Thread Dylan Baker
There are several checks that look for the 'result' in self._result and set it to fail if it's not there. Let's just make the default value of 'result' 'fail' and get rid of all of these checks. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 7 +-- 1 file

[Piglit] [Patch v2 13/13] exectest.py: remove try/except from PiglitTest.interpret_result

2014-04-16 Thread Dylan Baker
This removes a try/except that would catch everything and return a 'fail' status and a possible related error message. Instead, just let the method except and allow it to get caught and logged as a python exception. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py

[Piglit] [Patch v2 10/13] framework: stop passing duplicate arguments

2014-04-16 Thread Dylan Baker
attribute. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 132 + framework/gleantest.py | 14 ++-- framework/tests/gleantest_tests.py | 5 +- tests/es3conform.py| 9 ++- tests/igt.py

[Piglit] [Patch v2 06/13] framework/exectest.py: Don't pass redundant args to Test.Get_command_result()

2014-04-16 Thread Dylan Baker
This puts fullenv in Test.get_command_result() (since that's the only place it's actually used). Also don't pass self.command as an argument (with an additional assignment). v2: - replace comprehension with loop for readability Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework

Re: [Piglit] More exectest cleanups and refactors v2

2014-04-17 Thread Dylan Baker
at 11:06 PM, Dylan Baker baker.dyla...@gmail.com wrote: This is largely the same as the previous version, but with changes suggested by Ilia incorperated, and a replacment of v1 patch 9 with v2 patch 3. This results in a net change of 4 lines from v1 by patch 13, with three of those being

[Piglit] [PATCH] framework: fix potential bug in function signatures

2014-04-17 Thread Dylan Baker
things can happen. This can create some very strange and hard to pin down bugs. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/core.py | 14 -- tests/igt.py | 4 +++- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/framework/core.py b/framework

Re: [Piglit] [PATCH] framework: fix potential bug in function signatures

2014-04-17 Thread Dylan Baker
On Thursday, April 17, 2014 11:45:25 Ilia Mirkin wrote: On Thu, Apr 17, 2014 at 11:36 AM, Dylan Baker baker.dyla...@gmail.com wrote: It seems perfectly safe to do something like this: def foo(defaults=[]): stuff But its not. Python will only initialize defaults once, and store

[Piglit] [PATCH 1/2] framework: Fix html generation to work with recent changes to json

2014-04-18 Thread Dylan Baker
Recent changes to the JSON file spilt stderr, stdout, and returncode values out of a single 'info' string into three distinct values, but didn't update the summary to accept those values. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/summary.py | 4 +++- templates

[Piglit] [PATCH 2/2] framework: small refactor of test_result page generation

2014-04-18 Thread Dylan Baker
Previously each value of a dictionary was pulled out and passed one by one to mako, that results in a lot of values being passed. With this patch the dictionary is passed and the keys are pulled out in the mako. This is much cleaner and easier to read. Signed-off-by: Dylan Baker baker.dyla

Re: [Piglit] [PATCH 1/2] framework: Fix html generation to work with recent changes to json

2014-04-18 Thread Dylan Baker
On Friday, April 18, 2014 10:20:17 Ilia Mirkin wrote: On Fri, Apr 18, 2014 at 9:54 AM, Dylan Baker baker.dyla...@gmail.com wrote: Recent changes to the JSON file spilt stderr, stdout, and returncode values out of a single 'info' string into three distinct values, but didn't update

[Piglit] [PATCH] framework: Don't use eval in PiglitTest.interpret_result()

2014-04-21 Thread Dylan Baker
Python's eval() is not recommended for use anywhere at anytime, because it allows arbitrary code to be executed. Not using it is minimally invasive and is just a good idea. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py| 9 + tests/util/piglit-util.c | 6

Re: [Piglit] [PATCH] profile: Fix mixed concurrency runs

2014-04-21 Thread Dylan Baker
bump On Thursday, April 17, 2014 13:59:16 Dylan Baker wrote: Currently we call join after initializing both of the pools, which means that they run simultaneously. This patch fixes that by creating a helper function which sets off the pool, closes it, and then joins it. This fixes the problem

Re: [Piglit] How do I run the framework tests?

2014-04-23 Thread Dylan Baker
On Wednesday, April 23, 2014 05:14:59 PM Daniel Vetter wrote: On Wed, Apr 23, 2014 at 10:26:17AM -0400, Ilia Mirkin wrote: ~/src/piglit $ nosetests -e dmesg framework ..

Re: [Piglit] How do I run the framework tests?

2014-04-23 Thread Dylan Baker
On Wednesday, April 23, 2014 12:50:18 PM Ilia Mirkin wrote: On Wed, Apr 23, 2014 at 10:26 AM, Ilia Mirkin imir...@alum.mit.edu wrote: ~/src/piglit $ nosetests -e dmesg framework ..

[Piglit] [PATCH] dmesg_tests.py: Remove stupid timing tests

2014-04-23 Thread Dylan Baker
I never actually meant to push that test in the first place, but I figured it was there don't fix what ain't broken. But the test is broken, it fails sporadically and it isn't even that useful. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/tests/dmesg_tests.py | 33

Re: [Piglit] How do I run the framework tests?

2014-04-23 Thread Dylan Baker
On Wednesday, April 23, 2014 09:40:26 PM Ilia Mirkin wrote: On Wed, Apr 23, 2014 at 9:35 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Wednesday, April 23, 2014 05:14:59 PM Daniel Vetter wrote: On Wed, Apr 23, 2014 at 10:26:17AM -0400, Ilia Mirkin wrote: ~/src/piglit $ nosetests -e

Re: [Piglit] How do I run the framework tests?

2014-04-23 Thread Dylan Baker
On Wednesday, April 23, 2014 09:40:26 PM Ilia Mirkin wrote: On Wed, Apr 23, 2014 at 9:35 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Wednesday, April 23, 2014 05:14:59 PM Daniel Vetter wrote: On Wed, Apr 23, 2014 at 10:26:17AM -0400, Ilia Mirkin wrote: ~/src/piglit $ nosetests -e

Re: [Piglit] [PATCH] profile: Fix mixed concurrency runs

2014-04-23 Thread Dylan Baker
On Tuesday, April 22, 2014 07:03:08 PM Ilia Mirkin wrote: On Thu, Apr 17, 2014 at 4:59 PM, Dylan Baker baker.dyla...@gmail.com wrote: Currently we call join after initializing both of the pools, which means that they run simultaneously. This patch fixes that by creating a helper function

[Piglit] [Patch v2] profile: Fix mixed concurrency runs

2014-04-24 Thread Dylan Baker
all tests in a multithreaded pool - split lines differently for improved readability Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/profile.py | 29 ++--- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/framework/profile.py b/framework

Re: [Piglit] [PATCH] profile: Fix mixed concurrency runs

2014-04-24 Thread Dylan Baker
with the non-concurrent tests simultaneously. Marek So the bug was that with no -c or -1 option both pools were executed simultaneously, so a normal run ended up being concurrent with n+1 threads. On Thu, Apr 17, 2014 at 10:59 PM, Dylan Baker baker.dyla...@gmail.com wrote: Currently we call join

Re: [Piglit] [PATCH] profile: Fix mixed concurrency runs

2014-04-24 Thread Dylan Baker
On Thursday, April 24, 2014 18:39:44 Ilia Mirkin wrote: On Thu, Apr 24, 2014 at 6:33 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Friday, April 25, 2014 00:24:47 Marek Olšák wrote: I'm not sure I undertand this. I think the limitation for non-concurrent tests is that they cannot

[Piglit] [PATCH 2/3] summary.py: Treat subtests as groups, again

2014-04-24 Thread Dylan Baker
With this patch tests with subtests are treated as groups, their status is thrown away, and they inherit the 'worst' status from their children just like a group. This reverts commit de4b13de226e140313c3571e59a57438626da183. --- framework/summary.py | 86

[Piglit] [PATCH 1/3] summary_tests.py: Add tests for subtest handling

2014-04-24 Thread Dylan Baker
These tests are meant to show that subtest handling actually works. --- framework/tests/summary_tests.py | 77 +++- 1 file changed, 76 insertions(+), 1 deletion(-) diff --git a/framework/tests/summary_tests.py b/framework/tests/summary_tests.py index

[Piglit] [PATCH 3/3] framework/exectest.py: Only record one instance of subtests

2014-04-24 Thread Dylan Baker
Since subtests are better handled in the summary module there is no need to record these multiple times. This significantly reduces the size of the results file, (from 45M to 10M) --- framework/exectest.py | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git

[Piglit] [PATCH 1/4] integration_tests.py: Add basic tests for external test suite integration

2014-04-25 Thread Dylan Baker
These tests are not at any level meant to be complete or comprehensive, but rather just a set of basic sanity checks to help reduce breakage of integrated test suites. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/tests/integration_tests.py | 55

[Piglit] [PATCH 2/4] integration_tests.py: Add igt support

2014-04-25 Thread Dylan Baker
Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/tests/integration_tests.py | 11 +++ 1 file changed, 11 insertions(+) diff --git a/framework/tests/integration_tests.py b/framework/tests/integration_tests.py index 5446a5c..d984e2d 100644 --- a/framework/tests

[Piglit] [PATCH 4/4] integration_tests.py: Add oglconform support

2014-04-25 Thread Dylan Baker
Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/tests/integration_tests.py | 11 +++ 1 file changed, 11 insertions(+) diff --git a/framework/tests/integration_tests.py b/framework/tests/integration_tests.py index ea03cf4..53d8d4b 100644 --- a/framework/tests

[Piglit] [PATCH 01/12] framework/exectest.py: Fix a few pylint warnings

2014-04-25 Thread Dylan Baker
to a file. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/framework/exectest.py b/framework/exectest.py index 3056a78..6544ef2 100644 --- a/framework/exectest.py +++ b/framework/exectest.py

[Piglit] Final set of exectest re-factors

2014-04-25 Thread Dylan Baker
This series is the final set of patches in my extensive exectest cleanup effort. It's also by far the most aggressive and introduces the most visible changes. The biggest change is obviously that this series merges exectest, gleantest, shadertest, and glsl_parser_test into a single module called

[Piglit] [PATCH 06/12] framework: rename GleanTest.globalParams to GleanTest.GLOBAL_PARAMS

2014-04-25 Thread Dylan Baker
This is in keeping with PEP8 This commit generated via: find . -name '*py' | xargs sed -i -e 's!globalParams!GLOBAL_PARAMS!g' With manual cleanups in framework/tests/exectest_tests.py Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py| 4 ++-- framework

[Piglit] [PATCH 04/12] framework/exectest.py: Actually pass *args and **kwags in GleanTest

2014-04-25 Thread Dylan Baker
GleanTest has accepted **kwargs for some time, but didn't actually pass them to the super() call in it's constructor. This patch fixes that and also adds *args. At the moment we don't take addition args for the constructor, but we might at some point want to. Signed-off-by: Dylan Baker baker.dyla

[Piglit] [PATCH 12/12] framework/exectest.py: update docstrings and comments

2014-04-25 Thread Dylan Baker
Adds or updates docstrings to be accurate and fixes numerous spelling errors. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 109 +- 1 file changed, 82 insertions(+), 27 deletions(-) diff --git a/framework

[Piglit] [PATCH 08/12] framework: Merge glsl_parser_test into exectest

2014-04-25 Thread Dylan Baker
Merging the glsl_parser_test module into exectest has all the same advantages as merging the gleantest module did. Fewer imports across the board, fewer namespaces to deal with, and clearer class relationships. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py

[Piglit] [PATCH 02/12] framework/exectest.py: Use flyweight pattern for Test

2014-04-25 Thread Dylan Baker
this in a subclass by setting __slots__, that list is appended to the lists in the parent classes, so only new names need to be added. This cut the memory usage of loading tests.quick (and only loading) on my system from ~32M to ~24M. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework

[Piglit] [PATCH 05/12] framework/exectest.py: Make glean_executable constant PEP8 compliant

2014-04-25 Thread Dylan Baker
Changes internally used glean_executable to _GLEAN_EXECUTABLE, this is in keeping with python interface standards and PEP8. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/exectest.py b

[Piglit] [PATCH 09/12] framework: merge shadertest into exectest

2014-04-25 Thread Dylan Baker
This has all of the same advantages as merging GLSLParserTest did. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py| 93 +++ framework/shader_test.py | 121 --- framework/tests

[Piglit] [PATCH 07/12] framework/exectest.py: add check_for_skip_scenario to GleanTest

2014-04-25 Thread Dylan Baker
This moves the glean check out PiglitTest (since GleanTest doesn't descend from PiglitTest there could never be a PiglitTest with glean as an executable) and into GleanTest. If PIGLIT_PLATFORM is gbm glean tests will skip. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework

[Piglit] [PATCH 10/12] framework/exectest.py: Use abc metaclass for Test

2014-04-25 Thread Dylan Baker
raising NotImplementedError). Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py| 5 - framework/tests/exectest_test.py | 5 - 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/framework/exectest.py b/framework/exectest.py index ec4f724

[Piglit] [PATCH 03/12] framework: put GleanTest class in exectest module

2014-04-25 Thread Dylan Baker
This is the first step to merging the builtin test classes into a single module. It also fixes some problems with GleanTest.interpret_result() Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 21 +++ framework/gleantest.py | 49

[Piglit] [PATCH 11/12] framework/exectest.py: Mark several Test methods as not API

2014-04-25 Thread Dylan Baker
(). These methods shouldn't be called externally. It also changes the PIGLIT_PLATFORM constant to _PIGLIT_PLATFORM, again marking that it is meant for use in the module exclusively. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/exectest.py | 46

[Piglit] [PATCH 07/11] profile.py: Update docstrings and comments

2014-04-25 Thread Dylan Baker
Adds or fixes docstrings and comments --- framework/profile.py | 79 ++-- 1 file changed, 65 insertions(+), 14 deletions(-) diff --git a/framework/profile.py b/framework/profile.py index 0793f61..25f82b0 100644 --- a/framework/profile.py +++

[Piglit] cleanups for the profile module

2014-04-25 Thread Dylan Baker
This series aims to improve the code quality of the profile module. It's not actually as bad as it looks, since non of these changes are extensive. Most of these changes can be summed up as 'use the lazy version of a builtin function'. The majority of the code is in the first two patches, which

[Piglit] [PATCH 04/11] profile.py: use dict.iteritems() instead of keys

2014-04-25 Thread Dylan Baker
Doing dictionary lookup in a loop using a key is not a pythonic constuct, use iteritems() to provide both the key and value as names in the loop. --- framework/profile.py | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/framework/profile.py b/framework/profile.py index

[Piglit] [PATCH 05/11] profile: Remove unnecessary if statement

2014-04-25 Thread Dylan Baker
This particular if doesn't present big performance wins, nor does it affect the result of the code, but does make it harder to understand, so just remove it. --- framework/profile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/profile.py b/framework/profile.py

[Piglit] [PATCH 09/11] profile.py: stop exposing private methods of TestProfile

2014-04-25 Thread Dylan Baker
This patch stops exposing flatten_group_hierarchy and prepare_test_list by marking them with a leading underscore. These methods weren't meant to be called outside, and this is the pythonic way of letting users know that these are private methods. --- framework/profile.py | 16

[Piglit] [PATCH 11/11] framework: rename profile.loadTestProfile to profile.load_test_profile

2014-04-25 Thread Dylan Baker
This is a more pythonic name for this method. This patch was created with the following shell command: find . -name '*py' | \ xargs sed -i -e 's!loadTestProfile!load_test_profile!g' --- framework/profile.py | 8 framework/tests/profile_tests.py | 8

[Piglit] [PATCH 02/11] profile_tests.py: Add tests for the TestProfile class

2014-04-25 Thread Dylan Baker
This adds a good number of tests for various functions of the TestProfile class. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/tests/profile_tests.py | 218 +++ 1 file changed, 218 insertions(+) diff --git a/framework/tests/profile_tests.py

[Piglit] [PATCH 10/11] profile.py: set __all__

2014-04-25 Thread Dylan Baker
Setting the __all__ name in a module controls which names it exposes when imported. --- framework/profile.py | 6 ++ 1 file changed, 6 insertions(+) diff --git a/framework/profile.py b/framework/profile.py index db6fb45..4777c60 100644 --- a/framework/profile.py +++ b/framework/profile.py @@

[Piglit] [PATCH 01/11] profile_tests.py: Add tests for loadTestProfile

2014-04-25 Thread Dylan Baker
--- framework/profile.py | 2 +- framework/tests/profile_tests.py | 19 +++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/framework/profile.py b/framework/profile.py index 9f0bf48..21c2747 100644 --- a/framework/profile.py +++ b/framework/profile.py

[Piglit] [PATCH 06/11] profile.py: replace map() with generator expression

2014-04-25 Thread Dylan Baker
map() is considered semi-deprecated in python, since map() + lambda will always be more expensive than a comprehension or generator expression. --- framework/profile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/profile.py b/framework/profile.py index

[Piglit] [Patch v2 1/3] framework.log: Replace synchronized_self decorator

2014-04-25 Thread Dylan Baker
This replaces the synchronized_self decorator from piglit's threads module with a context manager (with foo: stuff). This is more standard python, and means having a little less hand rolled code around. v2: - fix mixed usage of __lock and _lock Signed-off-by: Dylan Baker baker.dyla...@gmail.com

[Piglit] [Patch v2 2/3] framework.core: Replace synchronized_self decorator

2014-04-25 Thread Dylan Baker
This removes the synchronized_self decorator and replaces it with a context manager. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/core.py | 85 --- 1 file changed, 43 insertions(+), 42 deletions(-) diff --git a/framework

[Piglit] [Patch v2 3/3] framework/threads.py: Remove file

2014-04-25 Thread Dylan Baker
This module contained only the synchronized_self decorator. Since that decorator has been replaced completely by the more idiomatic with lock syntax this is no longer needed. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/threads.py | 43

Re: [Piglit] [Patch v2 1/3] framework.log: Replace synchronized_self decorator

2014-04-26 Thread Dylan Baker
On Friday, April 25, 2014 05:23:47 PM Ilia Mirkin wrote: On Fri, Apr 25, 2014 at 4:45 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Friday, April 25, 2014 16:40:36 Ilia Mirkin wrote: On Fri, Apr 25, 2014 at 4:38 PM, Dylan Baker baker.dyla...@gmail.com wrote: This replaces

Re: [Piglit] [PATCH] framework: use formatted time values in the HTML report

2014-04-28 Thread Dylan Baker
On Monday, April 28, 2014 11:56:52 Thomas Wood wrote: v2: update for the changes to the test result template and check for None in the summary index time value Signed-off-by: Thomas Wood thomas.w...@intel.com --- framework/summary.py | 7 ++- 1 file changed, 6 insertions(+), 1

[Piglit] [PATCH] ARB_shader_texture_lod: Replace shell generator with python generator

2014-04-30 Thread Dylan Baker
don't need to check these simple generated tests in VCS. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- generated_tests/CMakeLists.txt | 4 + generated_tests/gen_texture_lod_tests.py | 181 ++ tests/all.py

Re: [Piglit] [PATCH 1/2] framework/dmesg.py: add a filtering mechanism

2014-04-30 Thread Dylan Baker
On Wednesday, April 30, 2014 12:20:31 Ilia Mirkin wrote: On Wed, Apr 30, 2014 at 12:12 PM, Thomas Wood thomas.w...@intel.com wrote: Only update the test status if at least one of the lines in the dmesg output matches the given regular expression. Would be nice to provide a mechanism to set

Re: [Piglit] [PATCH 3/3] piglit: Add piglit command

2014-04-30 Thread Dylan Baker
On Wednesday, April 30, 2014 13:42:09 Jordan Justen wrote: On Wed, Apr 30, 2014 at 11:18 AM, Dylan Baker baker.dyla...@gmail.com wrote: On Wednesday, April 30, 2014 10:28:57 Jordan Justen wrote: The piglit command is a wrapper command for the piglit-command.py scripts. For example

Re: [Piglit] [PATCH 3/3] piglit: Add piglit command

2014-04-30 Thread Dylan Baker
On Wednesday, April 30, 2014 15:21:37 Jordan Justen wrote: On Wed, Apr 30, 2014 at 1:58 PM, Dylan Baker baker.dyla...@gmail.com wrote: On Wednesday, April 30, 2014 13:42:09 Jordan Justen wrote: Anyway, piglit_cmd.py is the source that controls the piglit command, so it can evolve to present

Re: [Piglit] [PATCH 0/3] Update piglit install locations

2014-05-02 Thread Dylan Baker
Jordan, I think patches 1 and 2 look good. You have my r-b on those. I have a branch here: https://github.com/dcbaker/piglit piglit-cmd that IMO has a more elegant solution for a piglit executable. The big advantages I see to my approach is that there is very little hand rolled code, we don't

Re: [Piglit] [PATCH 0/3] Update piglit install locations

2014-05-02 Thread Dylan Baker
On Friday, May 02, 2014 12:41:03 Jordan Justen wrote: On Fri, May 2, 2014 at 12:50 AM, Dylan Baker baker.dyla...@gmail.com wrote: I think patches 1 and 2 look good. You have my r-b on those. Thanks. Can you add your r-b to the patches in your branch, since I expect you'd push them with your

[Piglit] [PATCH 1/4] cmake: Install under separate piglit directory

2014-05-02 Thread Dylan Baker
From: Jordan Justen jordan.l.jus...@intel.com Install paths updated: * $PREFIX/share/doc = $PREFIX/share/doc/piglit * $PREFIX/lib = $PREFIX/lib/piglit/lib * $PREFIX/bin = $PREFIX/lib/piglit/bin * etc... Signed-off-by: Jordan Justen jordan.l.jus...@intel.com Reviewed-by: Dylan Baker baker.dyla

[Piglit] [PATCH 3/4] framework: move executable functions to modules

2014-05-02 Thread Dylan Baker
interface. The original files could not be imported directly since they have dash (-) in their name, and python considered dash an illegal character for function, class, and modules names, and python would raise an ImportError. Signed-off-by: Dylan Baker baker.dyla...@gmail.com --- framework/programs

[Piglit] [PATCH 4/4] piglit: Add a toplevel piglit command

2014-05-02 Thread Dylan Baker
environment variable. v2: - Allow the name of the program to not be piglit (example: piglit-20140101) - Remove unused check from cmake - Install piglit as piglit${PIGLIT_INSTALL_VERSION}; when this variable is unset piglit will be installed simply as 'piglit' Signed-off-by: Dylan

[Piglit] [PATCH 0/4] Update piglit install locations v2

2014-05-02 Thread Dylan Baker
tested with an in tree build, and an out of tree build. Dylan Baker (2): framework: move executable functions to modules piglit: Add a toplevel piglit command Jordan Justen (2): cmake: Install under separate piglit directory cmake: Add version suffix for install paths CMakeLists.txt

[Piglit] [PATCH 2/4] cmake: Add version suffix for install paths

2014-05-02 Thread Dylan Baker
...@intel.com Reviewed-by: Dylan Baker baker.dyla...@gmail.com --- CMakeLists.txt | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c2203d0..e3eddba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -384,8 +384,14 @@ check_include_file(sys

Re: [Piglit] [PATCH 4/4] piglit: Add a toplevel piglit command

2014-05-05 Thread Dylan Baker
On Saturday, May 03, 2014 05:47:26 PM Jordan Justen wrote: On Fri, May 2, 2014 at 6:31 PM, Dylan Baker baker.dyla...@gmail.com wrote: This uses the functions created by the last commit to create a all-in-one piglit command. It uses argparse to parse partial commands and provide help

Re: [Piglit] [PATCH] framework/dmesg.py: add a filtering mechanism

2014-05-06 Thread Dylan Baker
On Tuesday, May 06, 2014 01:18:23 PM Thomas Wood wrote: Only update the test status if at least one of the lines in the dmesg output matches the given regular expression. v2: Style changes suggested by Ilia Mirkin and Dylan Baker Add a framework test for dmesg filtering Signed-off

Re: [Piglit] [PATCH] tests/igt.py: check for pass or skip before timeout

2014-05-06 Thread Dylan Baker
-by: Dylan Baker baker.dyla...@gmail.com signature.asc Description: This is a digitally signed message part. ___ Piglit mailing list Piglit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/piglit

Re: [Piglit] [PATCH 4/4] piglit: Add a toplevel piglit command

2014-05-06 Thread Dylan Baker
On Monday, May 05, 2014 09:15:47 AM Jordan Justen wrote: On Mon, May 5, 2014 at 1:35 AM, Dylan Baker baker.dyla...@gmail.com wrote: On Saturday, May 03, 2014 05:47:26 PM Jordan Justen wrote: On Fri, May 2, 2014 at 6:31 PM, Dylan Baker baker.dyla...@gmail.com wrote: This uses the functions

<    2   3   4   5   6   7   8   9   10   11   >