summaryrefslogtreecommitdiff
path: root/tests/gem_cpu_reloc.c
AgeCommit message (Collapse)Author
2017-10-18tests: Clean up igt_skip_on_simulation() usesArkadiusz Hiler
General update to reflect current state of things. Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com>
2017-06-29igt/gem_cpu_reloc: Fix presumed_offsetChris Wilson
The content of the batch may no longer match the offset/presumed_offset pair, so force the relocation by setting reloc.presumed_offset=-1 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-02-22igt: Start marking up GEM tests that require an alive GPU to functionChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-01-02igt: Mass conversion to to_user_pointer()Chris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-12-10Revert "igt: s/basic/sanitycheck/ on prior smoketesting"Daniel Vetter
This reverts commit 4f5efc5c844f6fe69209982463f9220f8f3951ed. There was a bit a misunderstanding on IRC between Chris&me. We want basic tests as sanity test to be run in the BAT CI. It's just unfortunate that right now we have fairly limited ability to absorb new ones, both because of a pile of existing bugs in the kernel and because the CI infrastructure is still being scaled out. The idea was just to remove the BAT tests added yesterday, not all of the ones we've had for a while longer. Cc: Chris Wilson <chris@chris-wilson.co.uk> Grumpily-acked-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2015-12-10igt: s/basic/sanitycheck/ on prior smoketestingChris Wilson
In times past, I added "basic" variants of tests just to ensure that the general principle of operation was sound before proceeding on to the main test (which typically looked at thrashing, i.e. were long and tedious and pointless if the test didn't even work in the normal situation). Since "basic" now collides with BAT, rename my trivial tests to "sanitycheck". Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-09-11convert drm_open_any*() calls to drm_open_driver*(DRIVER_INTEL) calls with cocciMicah Fedke
Apply the new API to all call sites within the test suite using the following semantic patch: // Semantic patch for replacing drm_open_any* with arch-specific drm_open_driver* calls @@ identifier i =~ "\bdrm_open_any\b"; @@ - i() + drm_open_driver(DRIVER_INTEL) @@ identifier i =~ "\bdrm_open_any_master\b"; @@ - i() + drm_open_driver_master(DRIVER_INTEL) @@ identifier i =~ "\bdrm_open_any_render\b"; @@ - i() + drm_open_driver_render(DRIVER_INTEL) @@ identifier i =~ "\b__drm_open_any\b"; @@ - i() + __drm_open_driver(DRIVER_INTEL) Signed-off-by: Micah Fedke <micah.fedke@collabora.co.uk> Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-08-21lib: add a single include headerThomas Wood
Add a header that includes all the headers for the library. This allows reorganisation of the library without affecting programs using it and also simplifies the headers that need to be included to use the library. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-05-14tests/gem_cpu_reloc: Fix gem_cpu_reloc OOM failureDerek Morton
On android with small memory footprints gem_cpu_reloc can fail due to OOM. Refactor gem_cpu_reloc into 2 tests, a basic test which performs 10 relocations and a full test which skips if there is insufficient memory. Changed the memory required test to better estimate the actual RAM used. v2: Addresed comments from Thomas Wood Signed-off-by: Derek Morton <derek.j.morton@intel.com> Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-04-03igt/gem_cpu_reloc: Pretty print execbuf failuresChris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=85672 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-12-04tests: add more test descriptionsThomas Wood
Add more test descriptions based on exiting comments. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-11-17lib/os: Pust igt_require into memory check functionDaniel Vetter
More in line with the usual igt pattern and simplifies the code - every called just wrapped it in igt_require. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
2014-09-08igt/gem_cpu_reloc: Terminate the bad batchChris Wilson
gen2 will read the batch up until it reaches the end as defined by the MI_BATCH_BUFFER_END command. Play nice and make sure that it does end on a MI_BB_END. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-08-12igt/gem_cpu_reloc: Update the memory requirementsChris Wilson
Use intel_check_memory() for accuracy and beautification Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-05-14tests: sprinkle igt loggingDaniel Vetter
All the cases that simply dump some debug information and couldn't be converted to some of the fancier macros. Some information output removed when it's redundant with the subtest status. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-23lib: extract igt_aux.[hc]Daniel Vetter
And shovel all the various helpers in there. Also move igt_set_vt_graphics_mode to igt_kms.h since the function is implemented in igt_kms.c. And it fits better. I kinda missed this in the prep work. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22lib: rename intel_gpu_tools.h to intel_io.hDaniel Vetter
With the header cleanup we can now give this header a suitable name, since it now really only contains register access and other I/O functions and assorted definitions. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22lib: unnecessary header removal for drmtest.h, part 1Daniel Vetter
Brought a few missing headers to light in ioctl_wrappers.h, too. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-12-10tests: roll out igt_simple_init/igt_simple_mainDaniel Vetter
Also use igt_skip a bit more to simplify some of the tests. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-11-15tests: More bdw falloutDaniel Vetter
This time misplaced parens. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-11-14tests: More bdw falloutDaniel Vetter
2013-11-07gem_cpu_reloc: Fixed botched BLIT conversionBen Widawsky
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-11-06tests/bdw: gem_cpu_relocBen Widawsky
support gen8 style blits Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2013-08-13tests: s/assert/igt_assertDaniel Vetter
Just a wholesale rollout for now, we can refine later on. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-08-12s/drmtest_/igt_/Daniel Vetter
Requested-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Damien Lespiau <damien.lespiau@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2013-07-18tests: Instrument tests run in simulation to run quicklyDamien Lespiau
We tweak the tests marked as runnable in simulation to run more quickly, more often then not at the expense of stress testing (which is of an arguable interest for the initial bring up in simulation). Hopefully the values chosen still test something, which is not always straightforward. It does run quickly, the number on an IVB machines are: $ time sudo IGT_SIMULATION=0 ./piglit-run.py tests/igt.tests foo [...] real 2m0.141s user 0m16.365s sys 1m33.382s Vs. $ time sudo IGT_SIMULATION=1 ./piglit-run.py tests/igt.tests foo [...] real 0m0.448s user 0m0.226s sys 0m0.183s Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2012-11-28tests: dont polute stderr if the test succeeds/skipsDaniel Vetter
Results in spurious 'warn' results in piglit. Also don't print progress indicators when not outputting to a terminal. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-10-02gem_cpu_reloc: Do another pass explicitly moving to the CPU write domainChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-02gem_cpu_reloc: Use the mappable aperture size!Chris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-02gem_cpu_reloc: And run the test in reverse to check with already bound batchesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-02gem_cpu_reloc: Fix for running on SNB+Chris Wilson
I work with these everyday and I still made a basic mistake. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-02tests: Add gem_cpu_relocChris Wilson
Attempt to stress test performing relocations whilst the batch is in the CPU domain. A freshly allocated buffer starts in the CPU domain, and the pwrite should also be performed whilst in the CPU domain and so we should execute the relocations within the CPU domain. If for any reason one of those steps should land it in the GTT domain, we take the secondary precaution of filling the mappable portion of the GATT. In order to detect whether a relocation fails, we first fill a target buffer with a sequence of invalid commands that would cause the GPU to immediate hang, and then attempt to overwrite them with a legal, if short, batchbuffer using a BLT. Then we come to execute the bo, if the relocation fail and we either copy across all zeros or garbage, then the GPU will hang. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>