[Mesa-dev] set.c vs. hash_table.c

Eric Anholt eric at anholt.net
Sun Dec 9 18:41:15 PST 2012

Brian Paul <brianp at vmware.com> writes:

> Hi Jordan,
> set.c and hash_table.c look a LOT alike.  Could the functions in set.c 
> be implemented in terms of the hash_table.c functions?  It seems 
> little silly to have so much duplicated code.

The idea of the set code is to save most of the memory in the case that
all you're doing is storing a set of pointers.  We've got some debug
code that also wants to use this in ir_validate.

Whether the set code is important enough to have just for these two
case, I'm not sure.  I wouldn't have imagined that people wrote code
using many of these object types until I encountered minecraft, though
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20121209/7737774c/attachment.pgp>

More information about the mesa-dev mailing list