summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2016-05-20 20:56:29 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2016-05-20 20:58:50 +0100
commita7d58541977f7922b04ecd13159e186d1086c312 (patch)
tree4381df4e1078a2062b9aa4a11f7fa6294a019a87 /tests
parent2b4c35efb132168933ba6660fcf556a033b0b17b (diff)
igt/gem_exec_gttfill: Limit to using 4GiB of GTT
Since we do not use the allow-48b GTT per-object flag, even on Broadwell+ we will be constrained to 4GiB of usage GTT. Also only do a single pass for BAT as suggested by Marius Vlad. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests')
-rw-r--r--tests/gem_exec_gttfill.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/gem_exec_gttfill.c b/tests/gem_exec_gttfill.c
index 59219236..19c0de6c 100644
--- a/tests/gem_exec_gttfill.c
+++ b/tests/gem_exec_gttfill.c
@@ -139,12 +139,14 @@ static void fillgtt(int fd, unsigned ring, int timeout)
igt_require(nengine);
size = gem_aperture_size(fd);
+ if (size > 1ull<<32) /* Limit to 4GiB as we do not use allow-48b */
+ size = 1ull << 32;
igt_require(size < (1ull<<32) * BATCH_SIZE);
count = size / BATCH_SIZE + 1;
igt_debug("Using %'d batches to fill %'llu aperture on %d engines\n",
count, (long long)size, nengine);
- intel_require_memory(count * nengine, BATCH_SIZE, CHECK_RAM);
+ intel_require_memory(count, BATCH_SIZE, CHECK_RAM);
memset(&execbuf, 0, sizeof(execbuf));
execbuf.buffer_count = 1;
@@ -195,7 +197,7 @@ igt_main
igt_fork_hang_detector(device);
igt_subtest("basic")
- fillgtt(device, 0, 10);
+ fillgtt(device, 0, 1); /* just enough to run a single pass */
for (e = intel_execution_engines; e->name; e++)
igt_subtest_f("%s", e->name)