summaryrefslogtreecommitdiff
path: root/tests/gem_exec_latency.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2017-02-23 02:04:31 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2017-02-23 02:09:10 +0000
commita7c9add6ff823a7c5bd440422fa84a748f08db0f (patch)
treefb21319c4949a44df4c5bb33ddefe5aae8c2ec8e /tests/gem_exec_latency.c
parentee4e38f9350fd8c69a3b228b8caff329fcfd87be (diff)
igt/gem_exec_latency: Assert the relocations are correct
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests/gem_exec_latency.c')
-rw-r--r--tests/gem_exec_latency.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/gem_exec_latency.c b/tests/gem_exec_latency.c
index 823bf538..9716eabb 100644
--- a/tests/gem_exec_latency.c
+++ b/tests/gem_exec_latency.c
@@ -164,12 +164,15 @@ static void latency_on_ring(int fd,
start = *reg;
for (j = 0; j < repeats; j++) {
+ uint64_t presumed_offset = reloc.presumed_offset;
+
execbuf.batch_start_offset = 64 * j;
reloc.offset =
execbuf.batch_start_offset + sizeof(uint32_t);
reloc.delta = sizeof(uint32_t) * j;
gem_execbuf(fd, &execbuf);
+ igt_assert(reloc.presumed_offset == presumed_offset);
}
end = *reg;
igt_assert(reloc.presumed_offset == obj[1].offset);