Commit 7763349a authored by Chris Wilson's avatar Chris Wilson

igt/gem_concurrent_blit: Separate out the combinatorial explosion

Apparently nobody else likes testing and debugging GEM coherency issues.
However, this also means that QA is skipping these vital tests. Split
out a set of canaries into igt/gem_concurrent_blit and keep the rest in
igt/gem_concurrent_all.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89497Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
parent c666a19e
......@@ -248,6 +248,11 @@ static struct {
} log_buffer;
static pthread_mutex_t log_buffer_mutex = PTHREAD_MUTEX_INITIALIZER;
const char *igt_test_name(void)
{
return command_str;
}
static void _igt_log_buffer_append(char *line)
{
pthread_mutex_lock(&log_buffer_mutex);
......
......@@ -202,6 +202,7 @@ bool igt_only_list_subtests(void);
static void igt_tokencat(__real_main, __LINE__)(void) \
const char *igt_test_name(void);
void igt_simple_init_parse_opts(int *argc, char **argv,
const char *extra_short_opts,
struct option *extra_long_opts,
......
......@@ -21,6 +21,7 @@ gem_bad_reloc
gem_basic
gem_caching
gem_close_race
gem_concurrent_all
gem_concurrent_blit
gem_cpu_reloc
gem_cs_prefetch
......
......@@ -52,6 +52,8 @@ gem_ctx_basic_CFLAGS = $(AM_CFLAGS) $(THREAD_CFLAGS)
gem_ctx_basic_LDADD = $(LDADD) -lpthread
gem_ctx_thrash_CFLAGS = $(AM_CFLAGS) $(THREAD_CFLAGS)
gem_ctx_thrash_LDADD = $(LDADD) -lpthread
gem_concurrent_all_SOURCES = gem_concurrent.c
gem_concurrent_blit_SOURCES = gem_concurrent.c
gem_fence_thrash_CFLAGS = $(AM_CFLAGS) $(THREAD_CFLAGS)
gem_fence_thrash_LDADD = $(LDADD) -lpthread
gem_fence_upload_CFLAGS = $(AM_CFLAGS) $(THREAD_CFLAGS)
......
......@@ -23,6 +23,7 @@ TESTS_progs_M = \
gem_caching \
gem_close_race \
gem_concurrent_blit \
gem_concurrent_all \
gem_cs_tlb \
gem_ctx_param_basic \
gem_ctx_bad_exec \
......
......@@ -27,9 +27,9 @@
*
*/
/** @file gem_concurrent_blit.c
/** @file gem_concurrent.c
*
* This is a test of pread/pwrite behavior when writing to active
* This is a test of pread/pwrite/mmap behavior when writing to active
* buffers.
*
* Based on gem_gtt_concurrent_blt.
......@@ -57,11 +57,12 @@
#include "intel_io.h"
#include "intel_chipset.h"
IGT_TEST_DESCRIPTION("Test of pread/pwrite behavior when writing to active"
IGT_TEST_DESCRIPTION("Test of pread/pwrite/mmap behavior when writing to active"
" buffers.");
int fd, devid, gen;
struct intel_batchbuffer *batch;
int all;
static void
nop_release_bo(drm_intel_bo *bo)
......@@ -908,7 +909,7 @@ run_basic_modes(const struct access_mode *mode,
{ "blt", blt_copy_bo, bcs_require },
{ "render", render_copy_bo, rcs_require },
{ NULL, NULL }
}, *p;
}, *pskip = pipelines + 3, *p;
const struct {
const char *suffix;
do_hang hang;
......@@ -922,7 +923,10 @@ run_basic_modes(const struct access_mode *mode,
struct buffers buffers;
for (h = hangs; h->suffix; h++) {
for (p = pipelines; p->prefix; p++) {
if (!all && *h->suffix)
continue;
for (p = all ? pipelines : pskip; p->prefix; p++) {
igt_fixture {
batch = buffers_init(&buffers, mode, fd);
}
......@@ -1052,11 +1056,13 @@ run_basic_modes(const struct access_mode *mode,
static void
run_modes(const struct access_mode *mode)
{
run_basic_modes(mode, "", run_single);
if (all) {
run_basic_modes(mode, "", run_single);
igt_fork_signal_helper();
run_basic_modes(mode, "-interruptible", run_interruptible);
igt_stop_signal_helper();
igt_fork_signal_helper();
run_basic_modes(mode, "-interruptible", run_interruptible);
igt_stop_signal_helper();
}
igt_fork_signal_helper();
run_basic_modes(mode, "-forked", run_forked);
......@@ -1069,6 +1075,9 @@ igt_main
igt_skip_on_simulation();
if (strstr(igt_test_name(), "all"))
all = true;
igt_fixture {
fd = drm_open_any();
devid = intel_get_drm_devid(fd);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment