summaryrefslogtreecommitdiff
path: root/tests/eviction_common.c
AgeCommit message (Collapse)Author
2014-07-21igt/gem_userptr_blits: New tests, old issuesChris Wilson
Introduce a new test to keep that we clean up on process exit (if the userptr is busy or it has been gtt mmapped). This revealed a few bugs in the existing tests so clean those up. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05igt/gem_evict_everything: Compute number of surfaces to saturate the apertureChris Wilson
The goal is to only fill the aperture, not all of memory, so fine-tune the computed number of surfaces, hopefully avoiding an integer overflow in the process. References: https://bugs.freedesktop.org/show_bug.cgi?id=79573 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-03igt/gem_evict_everything: Move assertionChris Wilson
If we move the assertion from out of the callback, we can get a much more useful error message. References: https://bugs.freedesktop.org/show_bug.cgi?id=79573 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-05-28Factor in kernel object overhead when checking available memory for testsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
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-02-26evictions: Limit the number of minor eviction surfaces to fit in RAMChris Wilson
We allocate more surfaces than used in a single pass in order to stress the eviction code between batches. The intent here is not to exercise swapping, and we fail to check that there is enough swap+memory to hold all our surfaces. So limit the number of surfaces we allocate to fit into RAM, and then require that the number of surfaces we need for testing is less than the number of surfaces we can allocate. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-02-04tests/eviction_common: Avoid submitting duplicate objectsTvrtko Ursulin
Make sure selection loop does not generate duplicates when it picks a subset of objects for a single exec buffer. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-02-04tests/gem_evict_everything: Factor out eviction logicTvrtko Ursulin
In preparation for userptr test we move the eviction logic into a common file so it can be used from both test cases. Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>