Commit 81ade89d authored by Chris Wilson's avatar Chris Wilson 😣

gem_render_tiled_blits: Trim usage to fit within RAM

This is a render correctness test, the intention is not to exercise the
swapper (but preferrably some eviction code).

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75247Signed-off-by: Chris Wilson's avatarChris Wilson <chris@chris-wilson.co.uk>
parent 4550a18a
......@@ -97,6 +97,11 @@ int main(int argc, char **argv)
return 1;
}
if (count > intel_get_total_ram_mb() * 9 / 10) {
count = intel_get_total_ram_mb() * 9 / 10;
printf("not enough RAM to run test, reducing buffer count\n");
}
printf("Using %d 1MiB buffers\n", count);
buf = malloc(sizeof(*buf)*count);
......
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