[igt-dev] [PATCH i-g-t] i915/gem_exec_gttfill: Run basic test on simulation

Chris Wilson chris at chris-wilson.co.uk
Fri Mar 22 07:19:01 UTC 2019


Quoting Prathap Kumar Valsan (2019-03-21 23:06:13)
> Basic test don't take long to complete, so allow basic test to
> run on simulation.
> ---
>  tests/i915/gem_exec_gttfill.c | 13 ++++++++-----
>  1 file changed, 8 insertions(+), 5 deletions(-)
> 
> diff --git a/tests/i915/gem_exec_gttfill.c b/tests/i915/gem_exec_gttfill.c
> index efd612bb..92c3cf62 100644
> --- a/tests/i915/gem_exec_gttfill.c
> +++ b/tests/i915/gem_exec_gttfill.c
> @@ -144,7 +144,8 @@ static void fillgtt(int fd, unsigned ring, int timeout)
>         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, BATCH_SIZE, CHECK_RAM);
> +       if (!igt_run_in_simulation())
> +               intel_require_memory(count, BATCH_SIZE, CHECK_RAM);

No. That is too ugly. You are basically saying that memory limits don't
matter for simulation -- unless the reader is aware of the convoluted
story in the setup and that we've previously marked as anything that
requires to check memory is not suitable for the slow simulator.

Why do you want to run this on the simulator? Write that test.
-Chris


More information about the igt-dev mailing list