[Lima] [Mesa-dev] [PATCH rfc 0/3] Be able to disable EGL/GLX_EXT_buffer_age

Qiang Yu yuq825 at gmail.com
Fri Jul 6 01:50:38 UTC 2018


On Fri, Jul 6, 2018 at 6:20 AM Eric Anholt <eric at anholt.net> wrote:
>
> Qiang Yu <yuq825 at gmail.com> writes:
>
> > Hi Emil,
> >
> > On Thu, Jul 5, 2018 at 9:54 PM Emil Velikov <emil.l.velikov at gmail.com> wrote:
> >>
> >> On 5 July 2018 at 14:31, Emil Velikov <emil.l.velikov at gmail.com> wrote:
> >> > Hi Qiang Yu
> >> >
> >> > On 5 July 2018 at 03:31, Qiang Yu <yuq825 at gmail.com> wrote:
> >> >> For GPU like ARM mali Utgard EGL/GLX_EXT_buffer_age will make
> >> >> performace worse. But mesa has no way to disable it.
> >> >>
> >> >> This patch series make driver be able to disable it and add a
> >> >> gallium pipe cap for gallium driver usage. Due to currently
> >> >> only out of tree lima driver need it, and not sure if this is
> >> >> the right way to disable it, so I send this RFC before lima be
> >> >> able to upstream.
> >> >>
> >> > Pretty sure we already have a way to handle that. Look for
> >> > glx_disable_ext_buffer_age - it was introduced for the VMWare driver.
> >> > Although we should:
> >> > a) tweak the name - kind of split if we need to
> >> > b) add glx/dri2 and egl support
> >> >
> >> Looking at the implementation - it uses a driver query, meaning that
> >> one could enable it at a later stage.
> >> No need to worry if the user has old drirc/etc as with current solution.
> >
> > Yes, use drirc to disable buffer age means it can be enabled by changing
> > the config (driver has to support it). But GPU like mali just don't want to
> > support it at all (need extra code do bad things).
>
> You must have the ability to load back into the tile buffer, so I think
> the driver should continue to support buffer age.  You don't know the
> complexity of recreating their whole frame, that decision should be up
> to them.
Yeah, mali can load back into the tile buffer. But buffer age ext has no
way to tell how much partial draw cost for different GPU, expose it
just tell application partial draw is cheaper.

Regards,
Qiang

> That said, it would be really nice for EGL to decide not to
> preserve buffers (and emit the resource invalidate call through gallium)
> when the client hasn't asked for a buffer age recently, and then just
> report the undefined buffer age value the first time they ask for it.


More information about the lima mailing list