Dave,
I don't oppose this new method -- it shouldn't be necessary to add fencing just
to use pb_cache --, but this method adds a new way of doing the same thing.
Does the underlying buffer support PIPE_BUFFER_USAGE_DONT_BLOCK? If so what
about doing:
boolean
pb_cache_is_buffer_compat()
{
void map;
map = pb_map(buf->buffer, PIPE_BUFFER_USAGE_DONT_BLOCK | PIPE_BUFFER);
if (map) {
/* TODO: cache the map value for the first map */
pb_unmap(buf->buffer);
return TRUE;
}
return FALSE;
}
Jose
________________________________________
From: Dave Airlie [[email protected]]
Sent: Sunday, March 07, 2010 20:36
To: Luca Barbieri
Cc: mesa
Subject: Re: [Mesa3d-dev] gallium cached bufmgr busy change
On Sun, Mar 7, 2010 at 9:44 PM, Luca Barbieri <[email protected]> wrote:
> I think you are supposed to do this using the fenced bufmgr over
> cached along with a (ideally userspace) fencing mechanism.
> If you can implement pb_busy, you should be able to implement
> fence_signalled in exactly the same way (making the fence handle a
> pointer to buffers should work for this purpose, if standalone fences
> are hard to do).
> The fenced bufmgr will only pass destruction requests to the wrapped
> bufmgr once the fences are signalled.
>
It just seemed a bit heavyweight, I don't want userspace fences, so why
do I have to jump though abstraction hoops?
The fencing solution isn't near as efficent from what I can see, as it
is designed around fences not buffer busy, I'll see if I can give it a try,
but I suspect it look and smell like a hack.
Dave.
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mesa3d-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Mesa3d-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev