summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-09-19lib: Add support for DROP_FREED in igt_drop_caches_set()Chris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-16tools/intel_reg: add kabylake register spec fileJani Nikula
Just do whatever skylake does. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-09-16lib: Export igt_debugfs_mount()Chris Wilson
Not everything we want from debugfs is under debugfs/dri. But we do want to share the code to find the debugfs mount point (and mount it if is not found). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-16lib: Add an iterator to generate primesChris Wilson
Primes are useful as input sources since they should not fall into any patterns that may be optimised by the drivers. An example of use this in a test driver: uint32_t seqno, inc, count; seqno = inc = count = 0; do { inc = igt_next_prime_number(inc); if (seqno + inc < seqno) break; seqno += inc; /* igt_assert_eq(test_inc(inc), seqno); */ count++; } while (1); printf("count=%u, seqno=%u, last=%u\n", count, seqno, inc); and prints "count=27878, seqno=4294845817, last=323381", or for simply generating the set of the first N prime numbers, use for_each_prime_number(prime, 100) printf("%lu ", prime); which prints 1 2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 64 67 71 73 79 83 89 97 101 103 107 109 113 127 131 137 139 149 151 157 163 167 173 179 181 191 193 197 199 211 223 227 229 233 239 241 251 257 263 269 271 277 281 283 293 307 311 313 317 331 337 347 349 353 359 367 373 379 383 389 397 401 409 419 421 431 433 439 443 449 457 461 463 467 479 487 491 499 503 509 521 Note that 1 is included in the set of prime numbers for convenience above. Mathematicians beware! The set of primes is computed using the Sieve of Eratosthenes, which basically just keeps a list of all multiples - any number not in list is therefore prime. As a bitmask of all integers is kept, it can be quite memory intensive for very large primes. A fallback to "trial division" is available just in case, but for large primes that is much slower. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-15lib/kms: Probe connectors from igt_enable_connectors()Chris Wilson
This fixes a failure when running kms_flip after booting on a bare system as nothing will have probed the connectors before hand. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-13igt/kms_cursor_legacy: Reduce flip/cursor ordering to basicsChris Wilson
The essence of the basic test is that neither the cursor nor the nonblocking flip stall the application of the next. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-13igt/gem_busy: Prevent banning when running multiple hang testsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-13igt/gem_busy: Actually flag the hang tests to cause a GPU hangChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-13igt/gem_busy: Replace extended busy-ioctl testing in bat with simpler testsChris Wilson
And replace with basic testing that rendering first is detected as being busy, and then will automatically retire. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-12igt/gem_exec_whisper: Add competing child processesChris Wilson
Execute the test in parallel in order to exercise a failure condition in reordering requests. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_exec_nop: Show more timing detailsChris Wilson
Min, average, exclude the post-exec sync time. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_exec_latency: Initial sketch for measuring execbuf cost in GPU cyclesChris Wilson
Similar to benchmarks/gem_latency, but looking more at the dispatch cost rather than wakeup cost, and looking for inter-engine costs. Still probably better as a perf test. ivb over the years: IGT-Version: 1.16-gebee919 (x86_64) (Linux: 3.10-3-amd64 x86_64) render: dispatch latency: 50.90, execution latency: 57.29 (target 4.64) bsd: dispatch latency: 41.45, execution latency: 41.43 (target 4.75) blt: dispatch latency: 41.02, execution latency: 41.00 (target 4.99) IGT-Version: 1.16-gebee919 (x86_64) (Linux: 4.8.0-rc5+ x86_64) render: dispatch latency: 12.61, execution latency: 15.44 (target 1.71) bsd: dispatch latency: 12.08, execution latency: 12.07 (target 1.80) blt: dispatch latency: 12.59, execution latency: 12.58 (target 1.85) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_ctx_switch: Increase execution weightChris Wilson
Add a heavier batch of (1M nops) in order to stress a context switch onto a busy engine. (The immediate goal is try and fill the GuC workqueue, but it seems like the lightweight test was enough anyway, as well as gem_exec_nop.) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_exec_nop: Refine the target calculationChris Wilson
The ideal execution time cannot be faster than the fastest ring! If all other rings were infinitely fast, the seed would be max/nengine. Given each is finite, this puts a floor on the ideal execution time. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_exec_nop: Check submitting nops to each engine in parallelChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08igt/gem_exec_nop: Relax assertion for parallel executionChris Wilson
In an ideal world, we should be able to execute on every engine in parallel and the single limiting factor would be how fast the GPU can execute. Due to the serialisation in execbuf, we would lockstep with execution to the slowest engine and so would execute the same number of cycles on each. However in CI, we are limited by how fast the driver is, particularly under invasive debugging. This makes asserting that the average time == max/nengine impossible, and reveals that the assertion is impossible to meet under general condition. It's an impractical regression test. Therefore we relax the assertion to only detect should something critically fail. Worst case behaviour is presumed that each ring runs sequentially, and so running N rings in parallel should take no longer than running N rings serially. (Pathologically it can be even slower if no batching on the rings occur). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-08kms_properties: Invalid atomic properties should return -ENOENTMaarten Lankhorst
This was already tested by kms_atomic when passing object id's as properties to set. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-09-08kms_cursor_legacy: Add cursor crc tests.Maarten Lankhorst
On skylake there's a add_all_affected_planes call that will make atomic commit use the old cursor state. Add a test that first does a page flip then cursor update to expose the issue. The test currently fails on the vblank wait, but that's a common issue affecting all the tests. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-09-07demo/Makefile.source: Compile intel_sprite_on when HAVE_LIBDRM_INTEL.marius vlad
Introduced with commit cd86866dec. Signed-off-by: Marius Vlad <marius.c.vlad@intel.com> Reviewed-by: Robert Foss <robert.foss@collabora.com>
2016-09-07benchmarks/gem_busy: Fix compile errorDerek Morton
The benchmark was failing with: gem_busy.c:158:8: error: implicit declaration of function 'intel_gen' is invalid in C99 [-Werror,-Wimplicit-function-declaration] gen = intel_gen(intel_get_drm_devid(fd)); The root cause was due to the local lib directory not being specified in benchmarks/Android.mk, resulting in intel_chipset.h from drm being used instead. This patch adds the lib path to the LOCAL_C_INCLUDES Signed-off-by: Derek Morton <derek.j.morton@intel.com> Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
2016-09-07kms_properties: Add invalid property test.Maarten Lankhorst
This will attempt to set any property from any type to each mode object, to ensure that only enumerated properties can ever set to a mode object. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-09-04benchmarks/gem_busy: Merge all the sync_file fences togetherChris Wilson
Instead of causing each engine to execute serially (and so only testing on fence underneath the sync_file) merge them all together (as we do for the other interfaces). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-02benchmarks/gem_latency: Measure fence wakeup latenciesChris Wilson
Useful for comparing the cost of explict fences versus implicit. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-02Updated NEWS, and bumped version to 1.16.Marius Vlad
Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
2016-09-02lib/igt_core: Wrap print_backtrace_sig_safe() with HAVE_LIBUNWIND.Marius Vlad
Reported-by: Petri Latvala <petri.latvala@intel.com> Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
2016-09-01igt/pm_rps: Remove reliance on guessing the busy workloadChris Wilson
Create an unbounded batch in order to ensure that the workload doesn't disappear before the wait and so we should be given the RPS waitboost. References: https://bugs.freedesktop.org/show_bug.cgi?id=97564 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-01igt/gem_ctx_bad_exec: Begone invalid negative testChris Wilson
Stop looking for an error for a valid combination. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97562 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-01igt/prime_vgem: Simplify inter-process flip checksChris Wilson
Avoid having both the child and parent do the same "did the flip" happen check with each looking for the same event on the same fd. The problem being that the child may fall asleep and by the time it wakes up to do its check, the parent has already eaten the event. So leave the checking that the flip does occur to the parent. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-01tests/Makefile.am: Add -Wno-unused-result to testsmarius vlad
Removes useless warnings if a caller of a function does not use its returned value(s). Mostly aesthetic. Signed-off-by: Marius Vlad <marius.c.vlad@intel.com> CC: Chris Wilson <chris@chris-wilson.co.uk> CC: Daniel Vetter <daniel@ffwll.ch>
2016-09-01lib/igt_core: Print stacktrace when receiving one of the crash signals.marius vlad
While at it add SIGFPE as a crash signal. v3: Remove calls to igt_assert_eq() as these are not async-safe. As one user of this method remove the function pointer and recursive call. (Chris Wilson) v2: Added some helpers to avoid printf() inside a signal handler. (Chris Wilson) Signed-off-by: Marius Vlad <marius.c.vlad@intel.com>
2016-09-01lib/intel_chipset: Fix compilation when enabling the debugger.marius vlad
Add IS_SANDYBRIDGE() macro used by debugger/eudb. Signed-off-by: Marius Vlad <marius.c.vlad@intel.com> CC: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-01autotools/: Allow check target to be invoked w/o the need to issue a build.Marius Vlad
We need to have the test list generated before running the check target. Migrated igt_command_line.sh to tests/ from lib/tests/, which allows to building the tests and execute the script. This would allow cleaning followed by a make check. Also assembler/ directory needs also to be adjusted in order for this to work. Kept the possibility to invoke tests/igt_command_line.sh to determine which test is failing. Signed-off-by: Marius Vlad <marius.c.vlad@intel.com> Url: https://patchwork.freedesktop.org/series/6539/ Reviewed-By: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-01lib: Make igt_command_line.sh selftest standaloneChris Wilson
Allow the casual user to run igt_command_line.sh to discover what make check is complaining about. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-30prime_vgem: Fix fence flippingChris Wilson
On the move to doing front/back flips, I managed to completely break the test by forgetting to pass the fence to be signaled. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-29benchmarks/gem_busy: Measure polling of sync_fileChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-29lib: Avoid using 2 writes to /proc/sys/vm/drop_cachesChris Wilson
As the second write is ignored (leading to lack of memory freeing and spuriously failing tests), just do everything from the one write. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-28benchmarks/gem_busy: Compare using wait-ioctl for busyness checkChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-28benchmarks/gem_busy: Exercise the busy ioctlChris Wilson
And include poll(dmabuf) for comparison. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-26igt/kms_flip: There's no such thing as bo-too-bigChris Wilson
Since we can now use the entire global GTT for display, we can handle framebuffers that no longer fit into the mappable aperture. Update the kms_flip/bo-too-big expectations. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97502 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-25tests: Add kms_properties test.Maarten Lankhorst
This is a simple test that only tries to set the current property values back. It exposes the issue that some connector properties only work when set through the legacy path, because i915 doesn't handle atomic connector properties yet. The other way around is true too: The atomic CRTC_ID connector property cannot be set through legacy means yet. This causes the connector tests to fail on i915. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-08-25igt_kms: Populate more members of connectors.Maarten Lankhorst
It's possible to make use of disconnected connectors, for example when overriding the mode or testing connector properties that don't need it to be connected. Support this by zeroing the mode in that case. We still return false, but this is ignored by commit. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-08-24igt/kms_cursor_legacy: Reduce scope of basic-cursor-vs-flipChris Wilson
Since we are experiencing too much noise in BAT from what just looks like scheduling delays in inspecting the vblank, reduce the basic test to the fundamentla: check that the cursor ioctl following the nonblocking flip/modeset occurs within the same vblank. Hopefully, CI + debug builds are fast enough to do get-vblank; flip; cursor; get-vblank within a single vblank period. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Imre Deak <imre.deak@intel.com> Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
2016-08-24igt/kms_busy: Fix subtest enumerationChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23igt/kms_cursor_legacy: Add missing newlineChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23lib/kms: Force connector probing on first useChris Wilson
In order for igt to run completely standalone, it must coldplug connectors on first use by forcing the probe. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23Revert "tests/gem_sync: Skip basic-store-each sub-test on BDW."Chris Wilson
This reverts commit 38f84e30e699451cac6c7b45cd603e67b1287f15.
2016-08-23igt/prime_vgem: Test both front/back flipChris Wilson
Check that we neither stall nor flip too early given active front/back buffers. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23igt/prime_vgem: Detect when the call to pageflip blocksChris Wilson
Identify whether it is the nonblockling page-flip request that blocks or the event is fired too early. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23igt/prime_vgem: Perform connector probe on startupChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-23Split out the kms tests from gem_busy to avoid the cairo dependencyChris Wilson
Make kms_busy a separate set of tests so that gem_busy is kept within the core set and not thrown out from Android due to the cairo dependency of rendering the fb. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>