[Mesa-dev] RFC: vega handle rework

Brian Paul brianp at vmware.com
Sun Jan 23 10:51:30 PST 2011


On 01/23/2011 11:40 AM, Henri Verbeet wrote:
> On 23 January 2011 18:20, Brian Paul<brianp at vmware.com>  wrote:
>>
>> The vega state tracker casts back and forth between pointers and the handle
>> types (VGHandle, VGPath, VGImage, etc).  Since handles are always 32-bit
>> VGuints, casting like this doesn't work with 64-bit pointers.
>>
>> This patch series implementes a pointer/handle mapping mechanism with a hash
>> table.
>>
>> If there's no concerns I'll commit in a day or two.
>>
> Is handle.c missing from patch 3?

Yup, new patches attached.


> Without having seen the code though,
> I wonder if a hash table isn't a bit overkill. I think the typical way
> to implement handle tables is to just use an array + free list.

That would be another option.  I don't have a strong opinion.  Feel 
free to re-do this with an array.  I don't plan on spending more time 
on it.

-Brian
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0001-vega-replace-casts-with-pointer-handle-conversion-fu.patch
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20110123/cc984f42/attachment-0001.asc>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0002-vega-remove-redundant-functions-found-elsewhere.patch
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20110123/cc984f42/attachment-0001.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0003-vega-implement-handler-pointer-conversion-using-a-ha.patch
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20110123/cc984f42/attachment-0002.asc>


More information about the mesa-dev mailing list