summaryrefslogtreecommitdiff
path: root/benchmarks/gem_blt.c
AgeCommit message (Collapse)Author
2016-10-15benchmarks/gem_blt: Directly compare the cmdparserChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-09-30benchmarks/gem_blt: Remove () causing integer overflowChris Wilson
In the middle of a line of double calculations is (int * int) and a potential overflow. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-05-09benchmarks/gem_blt: Add forked variantsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-03-01benchmarks/gem_blt: Measure the throughput of synchronous copiesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-01-27lib: Share common __gem_execbuf()Chris Wilson
An oft-repeated function to check EXECBUFFER2 for a particular fail condition. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-12-31benchmarks/gem_blt: Estimate memory bandwidth to improve test runtimeChris Wilson
If we autotune the workload to only take 0.1s and then repeat the measurements over 2s, we can bound the benchmark runtime. (Roughly of course! Sometimes the dispartity between main memory CPU bandwidth, and GPU execution bandwidth throws off the runtime, but that's the purpose of the benchmark!) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-11-12benchmarks/gem_blt: Fixup a couple of non-llc foiblesChris Wilson
When extending the batch for multiple copies, we need to remember to flag it as being in the CPU write domain so that the new values get flushed out to main memory before execution. We also have to be careful not to specify NO_RELOC for the extended batch as the execobjects will have been updated but we write the wrong presumed offsets. Subsequent iterations will be correct and we can tell the kernel then to skip the relocations entirely. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-11-10benchmarks/gem_blt: Report peak throughputChris Wilson
Report the highest throughput measured from a large set of runs to improve sensitivity. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-10-15benchmarks/gem_blt: Include igt.h in gem_blt.cDerek Morton
To fix a build error on android Signed-off-by: Derek Morton <derek.j.morton@intel.com> Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-10-12Replace __gem_mmap__{cpu,gtt,wc}() + igt_assert() with gem_mmap__{cpu,gtt,wc}()Ville Syrjälä
gem_mmap__{cpu,gtt,wc}() already has the assert built in, so replace __gem_mmap__{cpu,gtt,wc}() + igt_assert() with it. Mostly done with coccinelle, with some manual help: @@ identifier I; expression E1, E2, E3, E4, E5, E6; @@ ( - I = __gem_mmap__gtt(E1, E2, E3, E4); + I = gem_mmap__gtt(E1, E2, E3, E4); ... - igt_assert(I); | - I = __gem_mmap__cpu(E1, E2, E3, E4, E5); + I = gem_mmap__cpu(E1, E2, E3, E4, E5); ... - igt_assert(I); | - I = __gem_mmap__wc(E1, E2, E3, E4, E5); + I = gem_mmap__wc(E1, E2, E3, E4, E5); ... - igt_assert(I); ) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Stochastically-reviwewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-10-09Make gem_mmap__{cpu,gtt,wc}() assert on failureVille Syrjälä
Rename the current gem_mmap__{cpu,gtt,wc}() functions into __gem_mmap__{cpu,gtt,wc}(), and add back wrappers with the original name that assert that the pointer is valid. Most callers will expect a valid pointer and shouldn't have to bother with failures. To avoid changing anything (yet), sed 's/gem_mmap__/__gem_mmap__/g' over the entire codebase. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Stochastically-reviwewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-10-09Sprinkle igt_assert(ptr) after gem_mmap__{cpu,gtt,wc}Ville Syrjälä
Do the following ptr = gem_mmap__{cpu,gtt,wc}() +igt_assert(ptr); whenever the code doesn't handle the NULL ptr in any kind of specific way. Makes it easier to move the assert into gem_mmap__{cpu,gtt,wc}() itself. Mostly done with coccinelle, with some manual cleanups: @@ identifier I; @@ <... when != igt_assert(I) when != igt_require(I) when != igt_require_f(I, ...) when != I != NULL when != I == NULL ( I = gem_mmap__gtt(...); + igt_assert(I); | I = gem_mmap__cpu(...); + igt_assert(I); | I = gem_mmap__wc(...); + igt_assert(I); ) ...> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Stochastically-reviwewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-10-06benchmarks/gem_blt: Fix compilation after rebase and add batch-sizeChris Wilson
Add an option to do more than one copy per batch. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2015-10-06benchmarks: Measure BLT performanceChris Wilson
Execute N blits and time how long they complete to measure both GPU limited bandwidth and submission overhead. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>