From: Daniel Vetter <daniel@ffwll.ch>
To: Chris Wilson <chris@chris-wilson.co.uk>,
"Mateo Lozano, Oscar" <oscar.mateo@intel.com>,
"Intel-gfx@lists.freedesktop.org"
<Intel-gfx@lists.freedesktop.org>,
"Madajczak, Tomasz" <Tomasz.Madajczak@intel.com>,
"Rutkowski, Adam J" <adam.j.rutkowski@intel.com>,
"Jesse Barnes (jbarnes@virtuousgeek.org)"
<jbarnes@virtuousgeek.org>
Subject: Re: pin OABUFFER to GGTT
Date: Mon, 7 Jul 2014 22:43:33 +0200 [thread overview]
Message-ID: <20140707204333.GC17271@phenom.ffwll.local> (raw)
In-Reply-To: <20140701195427.GA11155@nuc-i3427.alporthouse.com>
On Tue, Jul 01, 2014 at 08:54:27PM +0100, Chris Wilson wrote:
> On Tue, Jul 01, 2014 at 05:16:30PM +0000, Mateo Lozano, Oscar wrote:
> > > The issue is they need:
> > >
> > > A) A buffer object.
> > > B) Bound to GGTT.
> > > C) That userspace knows the GGTT offset of, so that they can program
> > > OABUFFER with it.
> > > D) That userspace can map so that they can read the reported counters.
> > >
> > > They used to create a bo, call bo_pin on it, use args->offset to program
> > > OABUFFER (via MI_LOAD_REGISTER_IMM, I imagine), map it and read the
> > > counter values. They cannot do this anymore.
> >
> > The answer might be that all of this needs to be done by the kernel
> > itself, but then we need to provide an interface to userspace...
>
> Yes. If you need to pin a buffer for a register, then it needs to be
> handled by the kernel. Especially one that provides information about
> other users.
Short-circuiting the entire discussion here. Afaik there's two OA modes:
- inline with the batch with MI_REPORT_PERF
- global with the ringbuffer setup with the OABUFFER registers
The later should indeed be fully controlled by the kernel as Chris
suggested and exposed as an off-cpu performance monitoring unit through
the perf subsystem. Chris has rfc patches floating somewhere to do this
for other gpu perf data.
One fun thing here is the coordination between these two OA modes since
iirc they both use the same setup registers for the performance counter
configuration. No idea yet how to solve this.
But really userspace shouldn't program ggtt offset, not even
debug/performance measuring tools.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
next prev parent reply other threads:[~2014-07-07 20:43 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-01 16:24 pin OABUFFER to GGTT Mateo Lozano, Oscar
2014-07-01 16:30 ` Chris Wilson
2014-07-01 16:34 ` Mateo Lozano, Oscar
2014-07-01 16:51 ` Chris Wilson
2014-07-01 17:13 ` Mateo Lozano, Oscar
2014-07-01 17:16 ` Mateo Lozano, Oscar
2014-07-01 19:54 ` Chris Wilson
2014-07-02 6:40 ` Ben Widawsky
2014-07-02 6:55 ` Chris Wilson
2014-07-02 8:49 ` Mateo Lozano, Oscar
2014-07-02 10:31 ` Madajczak, Tomasz
2014-07-02 10:49 ` Damien Lespiau
2014-07-02 11:11 ` Madajczak, Tomasz
2014-07-02 13:19 ` Rutkowski, Adam J
2014-07-03 7:17 ` Damien Lespiau
2014-07-03 17:10 ` Ben Widawsky
2014-07-03 20:45 ` Ben Widawsky
2014-07-02 17:36 ` Ben Widawsky
2014-07-07 20:43 ` Daniel Vetter [this message]
2014-07-07 23:59 ` Bragg, Robert
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=20140707204333.GC17271@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=Intel-gfx@lists.freedesktop.org \
--cc=Tomasz.Madajczak@intel.com \
--cc=adam.j.rutkowski@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=jbarnes@virtuousgeek.org \
--cc=oscar.mateo@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox