Commit Graph

23 Commits

Author SHA1 Message Date
Chris Wilson 496f3ff044 uxa: Harden against failures to submit batchbuffers
If we fail to submit a batchbuffer, the driver is broken and likely to
continue to fail to render. Give up, and fallback to swrast so that the
session remains usable.

References: https://bugs.freedesktop.org/show_bug.cgi?id=59771
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-30 16:47:02 +00:00
Chris Wilson 441ef916ae intel: Throttle harder
Filling the rings is a very unpleasant user experience, so cap the
number of batches we allow to be inflight at any one time.

Interestingly, as also found with SNA, throttling can improve
performance by reducing RSS. However, typically throughput is improved
(at the expense of latency) by oversubscribing work to the GPU and a
10-20% slowdown is commonplace for cairo-traces. Notably, x11perf is
less affected and in particular application level benchmarks show no
change.

Note that this exposes another bug in libdrm-intel 2.4.40 on gen2/3.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-01-11 12:56:08 +00:00
Chris Wilson 5d6dd9c5a7 Convert generation counter to octal
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-11-30 12:12:49 +00:00
Dave Airlie 43a34186d1 intel: convert to new screen conversion APIs
The compat header takes care of the old server vs new server.

this commit was autogenerated from util/modular/x-driver-screen-scrn-conv.sh

Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-05-23 11:02:20 +01:00
Chris Wilson 219467ac8b uxa: Simplify flush tracking
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-03-15 12:43:12 +00:00
Chris Wilson bd8fafe0c4 uxa: Kill the complicated in-flight tracking
Reference leak hunting.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-03-15 12:43:11 +00:00
Chris Wilson 3771387ad1 Compile out UXA if so desired
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:15:39 +00:00
Daniel Vetter d0184b5909 snb: implement PIPE_CONTROL workaround
Sandybdrige requires an elaborate dance to flush caches without
hanging the gpu. See public docs Vol2Part1 1.7.4.1 PIPE_CONTROL
or the corrensponding code in mesa/kernel.

This (together with the corresponding patch for the kernel) seems to
fix the hangs in cairo-perf-traces I'm seeing on my snb machine.

v2: Incorporate review from Chris Wilson. For paranoia keep all three
PIPE_CONTROL cmds in the same batchbuffer to avoid upsetting the gpu.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2011-10-11 09:54:17 +02:00
Eric Anholt 79e59fb2a0 Add support for Ivybridge chipset.
This gets display and 2D blit acceleration up and running.  No Render
acceleration is provided yet.
2011-05-09 22:56:42 -07:00
Chris Wilson 3145530fee Ensure that the partial batch is flushed upon the blockhandler
Currently, we require that a batch containing a dirty bo be submitted
before we mark the device as requiring a flush. So if we never submit a
batch between block handlers, we can end up sleeping without ever
flushing either the partial batch or the rendering to the scanout.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=36776
Tested-by: Vasily Khoruzhick <anarsoul@gmail.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-05-07 20:04:18 +01:00
Chris Wilson 97e9557619 intel: Restore manual flush for old kernels
Daniel Vetter pointed out that the automagic flush by the kernel for the
busy-ioctl was only introduced upstream in 2.6.37. So we still need to
manually emit a flush on old kernels.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-04-08 13:38:48 +01:00
Daniel Vetter fb40bf2b33 Tell users to grab i915_error_state on gpu hangs
Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2011-04-08 12:37:35 +02:00
Chris Wilson 25521900df gen6: Invalidate texture cache
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-04-07 15:09:30 +01:00
Chris Wilson 6f104189bb Take advantage of the kernel flush for dirty bo in the busy ioctl
Rather than just creating and submitting a batch that simply contains a
flush in order to periodically ensure that rendering reaches the
scanout, we can simply ask the kernel whether the scanout is busy. The
kernel will then submit a flush on our behalf if it is dirty, which
takes advantage of the kernel's dirty state tracking.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-04-04 19:24:30 +01:00
Chris Wilson 79444291a3 i965: segregate each vertex element into its own buffer
Reduce the number of relocations emitted by only emitting one relocation
per vertex element per vertex buffer.

References: https://bugs.freedesktop.org/show_bug.cgi?id=35733
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-04-04 16:42:57 +01:00
Chris Wilson 55c5f1876e Wait on the current buffer to complete when running synchronously.
And remove the vestigal wait upon changing crtc as this is more properly
done in the kernel.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-12-03 14:05:30 +00:00
Chris Wilson 3cc74044ce i965: Amalgamate surface binding tables
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-12-03 14:05:30 +00:00
Chris Wilson a1fa0dbfda i965: Upload an entire vbo in a single pwrite, rather than per-rectangle
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-12-03 14:05:30 +00:00
Chris Wilson a44a63d2ff Wait for any pending rendering before switching modes.
A perennial problem we have is the accursed WAIT_FOR_EVENT hangs, which
occur when we switch the framebuffer before the WAIT_FOR_EVENT completes
and upsets the GPU.

We have tried more subtle approaches to detected these and fix them up in
the kernel, to no avail. What we need to do is to delay the framebuffer
flip until the WAIT completes, which is quite tricky in the kernel
without new ioctls and round-trips. Instead, apply the big hammer from
userspace and synchronise all rendering before changing the framebuffer.
I expect this not to cause noticeable latency on switching modes (far
less than the actual modeswitch) and should stop these hangs once and
for all.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=31401 (...)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-11-05 10:07:46 +00:00
Zou Nan hai 5bed685f76 add BLT ring support
gen6+ platform has a BLT engine with seperate
command streamer to support BLT commands.

Signed-off-by: Zou Nan hai <nanhai.zou@intel.com>
[ickle: merge trivial conflict]
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-11-01 10:37:51 +00:00
Xiang, Haihao 3213849907 Xv: setup pipeline for Xv on Sandybridge
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
2010-11-01 08:51:13 +08:00
Chris Wilson 4083197a44 Include a chipset generation number to clarify device specific paths.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-07 13:26:07 +01:00
Chris Wilson 5c663ce844 Rename common infrastructure to the intel namespace.
After splitting out the i810 driver into its own legacy directory, we
can identify the common routines not as i830 but as intel. This
clarifies the code which *is* i830 specific.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-06-25 13:18:01 +01:00