19 Commits

Author SHA1 Message Date
Tvrtko Ursulin
bf57e93f50 igt/gem_userptr_benchmark: Fix for upstream ioctl number
Hardcoding has upsides and downsides.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-07-23 14:52:31 +02:00
Daniel Vetter
1b55886c4b test/gem_userptr_*: Fix compile fail
Also shut up warnings. Those revealed incorrect usage of local
variables in conjunction with igt_fixture/igt_subtest. Since those use
longjmps we need to move the out of the stackframe those magic blocks
are declared in.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-04-25 17:54:08 +02:00
Tvrtko Ursulin
d3057d7a1e tests/gem_userptr_benchmark: Benchmarking userptr surfaces and impact
This adds a small benchmark for the new userptr functionality.

Apart from basic surface creation and destruction, also tested is the
impact of having userptr surfaces in the process address space. Reason
for that is the impact of MMU notifiers on common address space
operations like munmap() which is per process.

v2:
  * Moved to benchmarks.
  * Added pointer read/write tests.
  * Changed output to say iterations per second instead of
    operations per second.
  * Multiply result by batch size for multi-create* tests
    for a more comparable number with create-destroy test.

v3:
  * Use ALIGN macro.
  * Catchup with big lib/ reorganization.
  * Removed unused code and one global variable.
  * Fixed up some warnings.

v4:
  * Fixed feature test, does not matter here but makes it
    consistent with gem_userptr_blits and clearer.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Brad Volkin <bradley.d.volkin@intel.com>
Reviewed-by: Brad Volkin <bradley.d.volkin@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-04-25 17:48:49 +02:00
Tvrtko Ursulin
5d7649690c benchmarks: Build them on Android.
They build fine so give them some exposure.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Brad Volkin <bradley.d.volkin@intel.com>
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-04-24 13:49:20 +01:00
Daniel Vetter
c03c6ceb29 lib: rename intel_gpu_tools.h to intel_io.h
With the header cleanup we can now give this header a suitable name,
since it now really only contains register access and other I/O
functions and assorted definitions.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 21:34:29 +01:00
Daniel Vetter
254f19ba8d lib: unnecessary header removal for drmtest.h, part 2
I've left unistd.h in it - it's not strictly required but most users
of drmtest.h want it for the open helpers, and then you kinda need to
close that file descriptor again ...

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 21:29:01 +01:00
Daniel Vetter
e49ceb8690 lib: unnecessary header removal for drmtest.h, part 1
Brought a few missing headers to light in ioctl_wrappers.h, too.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 21:07:37 +01:00
Ben Widawsky
f4dfa37e85 bdw: Update obvious missing blit support
This provides a macro that allows us to update all the arbitrary blit
commands we have stuck throughout the code. It assumes we don't actually
use 64b relocs (which is currently true). This also allows us to easily find
all the areas we need to update later when we really use the upper dword.

This block was done mostly with a sed job, and represents the easier
in test blit implementations.

v2 by Oscar: s/OUT_BATCH/BEGIN_BATCH in BLIT_COPY_BATCH_START

CC: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Oscar Mateo <oscar.mateo@intel.com>
2013-11-06 09:34:35 -08:00
Daniel Vetter
662d732199 lib: extract kmstest_create_fb
We should get more kms tests soon, and not needing to copy-paste a
nice test pattern should be useful.

That establishes a firm depency of i-g-t on cairo over everything, but
I don't care so much about that.

Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-05-22 15:56:29 +02:00
Alan Coopersmith
5c4e041dc8 Make benchmarks also link against libpciaccess
Fixes Solaris build error on build of intel_upload_blit_large:

Undefined			first referenced
 symbol  			    in file
pci_device_probe                    ../lib/.libs/libintel_tools.a(intel_pci.o)  (symbol belongs to implicit dependency libpciaccess.so.0)
pci_system_init                     ../lib/.libs/libintel_tools.a(intel_pci.o)  (symbol belongs to implicit dependency libpciaccess.so.0)
pci_device_find_by_slot             ../lib/.libs/libintel_tools.a(intel_pci.o)  (symbol belongs to implicit dependency libpciaccess.so.0)
ld: fatal: symbol referencing errors. No output written to intel_upload_blit_large

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-01-24 11:38:10 +01:00
Gaetan Nadon
3ceb75828c Benchmark: use correct src and build location
Headers are found under top_srcdir/...
Haeders are CPP flags, not C Flags
AM_CPPFLAGS, AM_CFLAGS and LDAAD apply to all targets.
libintel_tools.la is located in top_builddir.

Acked-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
2012-01-12 09:13:08 -05:00
Gaetan Nadon
665b86664a config: use project wide xorg warnings variable
Use CWARNFLAGS as in all of xorg. There seems to be no reason why this
module should be different. The warnings were updated recently
for those who install the latest util-macros.

Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-01-04 10:47:11 +01:00
Gaetan Nadon
6540ed2112 Use standard .gitignore file and layout
Reusing xorg code saves maintenance in the long term.

Now that m4/.gitignore is removed, the -I m4 ${ACLOCAL_FLAGS}
must be removed to avoid build breakage as m4 is generated and not
part of the git source.

Acked-by: Cyril Brulebois <kibi@debian.org>
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-01-04 10:47:10 +01:00
Daniel Vetter
593cb1874a always require libdrm
... and also add the missing files to lib/Makefile.am

Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2011-11-01 17:04:44 +01:00
Chris Wilson
d4d769a432 Prepare for split BLT ring on Sandybridge.
Depends on libdrm 057fab3382c02af54126ce395c43d4e6dce9439a

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=31123
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-26 11:46:52 +01:00
Chris Wilson
95374225e8 Enable compilation on non-Intel, non-DRM systems.
A few of the tools can be performed post-mortem from a different system,
so it is useful to be able to compile those tools on those foreign
systems. Obviously, any program to interact with the PCI device or talk
to GEM will fail on a non-Intel system.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-04-08 12:17:31 +01:00
Eric Anholt
cb5a35fe8e Add a couple of other intel_upload_blit_large variants for comparison. 2009-03-31 10:01:07 -07:00
Eric Anholt
7889abd263 intel_upload_blit_*: Fix reporting and generate junk instead of using random.
Turns out that random completely overwhelmed the cost of the driver stuff
in _large.c.  I definitely want to generate data, but still be able to see
the driver's responsibility.
2009-03-30 19:09:00 -07:00
Eric Anholt
8c64183a46 Initial import of intel-graphics-tools with some microbenchmarks. 2009-03-26 17:15:11 -07:00