From f57f55e4daf2ef9c60242f22134f0f4e06117ace Mon Sep 17 00:00:00 2001 From: Ben Widawsky Date: Wed, 9 Oct 2013 15:51:34 -0700 Subject: [PATCH] tests/bdw: Port storedw_loop_vebox to gen8 I chose not to implement this in the same way as Zhao Yakui because I was lazy. Signed-off-by: Ben Widawsky --- tests/gem_storedw_loop_vebox.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/tests/gem_storedw_loop_vebox.c b/tests/gem_storedw_loop_vebox.c index 27f970a5..2a494ea3 100644 --- a/tests/gem_storedw_loop_vebox.c +++ b/tests/gem_storedw_loop_vebox.c @@ -56,14 +56,18 @@ store_dword_loop(int divider) int cmd, i, val = 0; uint32_t *buf; + printf("running storedw loop on blt with stall every %i batch\n", divider); + cmd = MI_STORE_DWORD_IMM; for (i = 0; i < SLOW_QUICK(0x100000, 0x10); i++) { BEGIN_BATCH(4); OUT_BATCH(cmd); - OUT_BATCH(0); /* reserved */ + if (intel_gen(batch->devid) < 8) + OUT_BATCH(0); /* reserved */ OUT_RELOC(target_buffer, I915_GEM_DOMAIN_INSTRUCTION, I915_GEM_DOMAIN_INSTRUCTION, 0); + BLIT_RELOC_UDW(batch->devid); OUT_BATCH(val); ADVANCE_BATCH(); @@ -117,8 +121,10 @@ int main(int argc, char **argv) store_dword_loop(1); store_dword_loop(2); - store_dword_loop(3); - store_dword_loop(5); + if (!igt_run_in_simulation()) { + store_dword_loop(3); + store_dword_loop(5); + } drm_intel_bo_unreference(target_buffer); intel_batchbuffer_free(batch);