All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: Peter Clifton <pcjc2@cam.ac.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: Corruption in glxgears with Compiz
Date: Sat, 23 Oct 2010 18:48:47 +0100	[thread overview]
Message-ID: <5b55a1$ietjas@fmsmga002.fm.intel.com> (raw)
In-Reply-To: <1287834125.2578.6.camel@pcjc2lap>

On Sat, 23 Oct 2010 12:42:05 +0100, Peter Clifton <pcjc2@cam.ac.uk> wrote:
> Your patch works a treat.. I knew mine was really only a band-aid which
> forced a flush on the pending indiscriminately, and was glad to see the
> proper fix. 
> 
> Really difficult to get your head round all this flush / invalidate
> stuff. I get the idea, but in practice it is very confusing due to the
> fact it is all deferred / scheduled work, and both subtly different
> concepts (flush / invalidate) concepts are handled by the same action on
> the GPU, and very similar code! Very easy to muddle current / pending
> ring in my head, for example.
> 
> You replied to Alexey that the patch is only a stop gap, and inter-ring
> synchronisation is the real challenge. I guess that is something you'll
> be forced to look at with the new Sandybridge chipset having a separate
> ring for BLT operations?

Exactly. We already have the issue on i965 with the Bitstream Decoder ring
which handles video separate from the render ring. Fortunately no one has
fallen over the lack of synchronisation there since the API design makes
interoperating GL/RENDER/Video so difficult. Even worse is that it is only
with Sandybridge that we have the ability to insert semaphores onto the
ring to handle inter-ring synchronisation on the GPU, otherwise we will
simply have to wait on retirement when transferring ownership from one
ring to another.  Is it worth the additional complexity to have buffers
reside on multiple rings at the same time? Possibly if we do start mixing
video + GL.  Anyway with the BLT split, handling synchronisation will
become an issue.
 
> I'm just looking for fps with my circuit board rendering GL code at the
> moment.. that's why I'm following git HEAD stuff, to see if the drivers
> can unlock some performance in the code I'm writing. I'm struggling to
> profile just what the bottleneck is!

Aye, profiling GPU code at the moment is a hard problem. If you do find
some CPU bottlenecks, they're usually the easiest to fix. What may help is
to sync every operation and see what the relative times + relative
frequencies to work out the rate limiting step and then see if you can
break it down further and repeat. (Even if we had a GPU callgrind, given
the disconnect between what is executed on the GPU and GL, it may not be
obvious how to improve the code.) uprof may help here given the
annotations Robert Brag has made for mesa profiling.

We're always eager to improve our code to get the most of our admittedly
lack-luster GPUs. Even suggests on what tools would be useful or
improvements we could make to improve profiling/development are most
welcome.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre

  reply	other threads:[~2010-10-23 17:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-22 12:53 Corruption in glxgears with Compiz Peter Clifton
2010-10-22 13:39 ` Chris Wilson
2010-10-22 14:04   ` Alexey Fisher
2010-10-22 19:10   ` Peter Clifton
2010-10-22 19:29     ` Chris Wilson
2010-10-22 19:38       ` Peter Clifton
2010-10-22 20:41       ` Peter Clifton
2010-10-23  3:35       ` Peter Clifton
2010-10-23  4:07         ` Peter Clifton
2010-10-23  8:23           ` Alexey Fisher
2010-10-23  9:10           ` Chris Wilson
2010-10-23  9:43             ` Alexey Fisher
2010-10-23 10:07               ` Chris Wilson
2010-10-23 11:42             ` Peter Clifton
2010-10-23 17:48               ` Chris Wilson [this message]
2010-10-23 18:33                 ` Peter Clifton
2010-10-24 23:06                 ` Peter Clifton
2010-10-22 19:13   ` Peter Clifton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='5b55a1$ietjas@fmsmga002.fm.intel.com' \
    --to=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=pcjc2@cam.ac.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.