[Mesa-dev] Gallium proposal: add a user pointer in pipe_resource

Marek Olšák maraeo at gmail.com
Mon Jan 31 10:46:28 PST 2011


On Mon, Jan 31, 2011 at 3:17 PM, Keith Whitwell <keithw at vmware.com> wrote:

> On Sat, 2011-01-29 at 15:12 -0800, Marek Olšák wrote:
> >
> >
> > Hi,
> >
> > I am proposing to add a pointer to a user buffer in pipe_resource.
> > There are two reasons for this:
> >
> > 1) I would like to have a way to query outside of a driver whether a
> > buffer is a user buffer. Simply comparing the pointer with NULL would
> > do the trick.
> >
> > 2) I would like to efficiently obtain a pointer to a user buffer
> > outside of a driver without going through the sequence of functions
> > get_transfer, transfer_map, transfer_unmap, and transfer_destroy.
> >
> > This will allow to move more driver-specific code to auxiliary/util.
> >
> >
>
>
> Marek,
>
> I have to say my preference would have been to see user buffers fade
> away in favour of things like inline transfers.  That said you're much
> more active than I am in looking at this right now, so I don't want to
> get in the way of your progress.
>
> I guess my biggest problem with user buffers is how poorly defined their
> semantics are.  For instance, what does it really mean to get write
> transfer into a userbuffer?   Will you be updating the original
> application-owned memory?
>

Hi Keith,



More information about the mesa-dev mailing list