On Tue, 31 Mar 2009 12:39:17 -0700
Eric Anholt <e...@anholt.net> wrote:

> On Fri, 2009-03-27 at 15:48 -0700, Jesse Barnes wrote:
> > On Fri, 27 Mar 2009 22:53:00 +0100
> > Jakob Bornecrantz <wallbra...@gmail.com> wrote:
> > 
> > > On Fri, Mar 27, 2009 at 8:58 PM, Jesse Barnes
> > > <jbar...@virtuousgeek.org> wrote:
> > > > This patch speeds up drmModeGetConnector by pre-allocating mode
> > > > & property info space before calling into the kernel.  In many
> > > > cases this pre-allocation will be sufficient to hold the
> > > > returned values (it's easy enough to tweak if the common case
> > > > becomes larger), which means we don't have to make the second
> > > > call, which saves a lot of time.
> > > >
> > > > Any comments or problems with the patch?
> > > 
> > > Looks good, I do wonder how much time do we save on doing pre
> > > allocation, just curious? Anyways the patch is
> > > Acked-by: Jakob Bornecrantz <wallbra...@gmail.com>
> > > 
> > > Cheers Jakob.
> > 
> > Some of my testing showed it took about .3s for a
> > drmModeGetConnector call and my testing showed this decrease a lot
> > with the pre-allocation (conveniently lost the test results
> > though).  Theoretically it should be about half the cost with
> > pre-allocation, which adds up if you multiply by the number of
> > outputs.
> 
> Seems like the ioctl needs a flag for "did the user want me to go
> reprobe things?" like we did in the X Server.

Yeah or a new ioctl... we'll need a new libdrm function for that at the
very least for compatibility.

-- 
Jesse Barnes, Intel Open Source Technology Center

------------------------------------------------------------------------------
--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to