[Nouveau] "enable ctxprog xfer only when we need it to save power" introduces big performance regression
marcin.slusarz at gmail.com
Wed Dec 28 17:38:50 PST 2011
On Thu, Dec 29, 2011 at 12:58:35AM +0100, Martin Peres wrote:
> On 28/12/2011 22:39, Marcin Slusarz wrote:
> > Heh, with page flipping enabled, regression is still there, only smaller
> > (61->54, instead of 49 FPS).
> > I want my Nouveau performance back ;)
> > ---
> > From: Marcin Slusarz<marcin.slusarz at gmail.com>
> > Subject: [PATCH] drm/nv50/gr: make "xfers only in ctxprog" optional
> > Commit fbba036a56fe0e5c5e8c91daf3fa211f88d94a03
> > "drm/nv50/gr: enable ctxprog xfer only when we need it to save power"
> > introduced performance regression.
> > So revert to previous behaviour and add module option (nv50_xfer_ctxprog=0/1)
> > to restore it back.
> > Signed-off-by: Marcin Slusarz<marcin.slusarz at gmail.com>
> I'm really sorry about not following up to your many emails you sent me
> in the past.
> I now have time to work on this issue and I would like a little more
> information if you don't mind. Could you do a mmiotrace and look at what
> nvidia does in their ctxprog for your specific card ?
Nvidia does the same, see http://paste.pocoo.org/show/500376/ (we talked about
it on IRC on 30 Oct). If you want me to get something else out of the mmiotrace,
just tell me.
> If nVidia does the same thing as we do, well, you'll have to wait for
> something I've been thinking for some times now.
> What we want is to define power consumption profiles. A simple example
> is, when on battery, you don't want to save as much power as possible
> but when you are on sector, you may want to get the full performance out
> of your card (You may also don't mind the performance loss, but one
> thing at a time).
> Ben (darktama) has recently talked about introducing a kind of automatic
> reclocking kind of like what radeon does. That is to say, having
> performance profiles that are switched according to the energy source
> (battery / sector). This automatic behaviour could then be overriden by
> the user, just like radeon.
> We would then turn some nobs according to the current performance
> profile. One of these nobs could be xfer on some specific cards (yours).
> Would that solution suit you?
Sounds good. I initially thought about connecting it to reclocking, but your
idea is even better - xfers enablement could depend only on power source.
I tried to implement xfers runtime switching, but couldn't figure out how to
change ctxprog behaviour without rebuilding and reuploading whole thing.
Reading host-writable memory from ctxprog would be enough.
> Clearly, introducing a new kernel
> parameter isn't an acceptable solution to the problem.
Yeah, I just wanted to start the discussion.
More information about the Nouveau