summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/hash_table.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: fix inconsistent function declaration, definitionsBrian Paul2013-07-121-2/+2
| | | | | To silence MSVC warnings that the declaration and definitions were different.
* Consolidate some redundant definitions of ARRAY_SIZE() macro.Paul Berry2013-02-081-2/+1
| | | | | | | | | | | | | | | | | | | | | Previous to this patch, there were 13 identical definitions of this macro in Mesa source. That's ridiculous. This patch consolidates 6 of them to a single definition in src/mesa/main/macros.h. Unfortunately, I wasn't able to eliminate the remaining definitions, since they occur in places that don't include src/mesa/main/macros.h: - include/pci_ids/pci_id_driver_map.h - src/egl/drivers/dri2/egl_dri2.h - src/egl/main/egldefines.h - src/gbm/main/backend.c - src/gbm/main/gbm.c - src/glx/glxclient.h - src/mapi/mapi/stub.c I'm open to suggestions as to how to deal with the remaining redundancy. Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: Replace random with standard C rand.Vinson Lee2012-11-121-1/+1
| | | | | | BSD random is not available on some compilers. Signed-off-by: Vinson Lee <[email protected]>
* mesa: Import a copy of the open-addressing hash table code I wrote.Eric Anholt2012-11-121-0/+442
Mesa's chaining hash table for object names is slow, and this should be much faster. I namespaced the functions under _mesa_*, to avoid visibility troubles that we may have had before with hash_table_* functions. v2: Move .c file to main/, const a few things, clean up loop conditions, add/extend some comments. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Chad Versace <[email protected]> Acked-by: Kenneth Graunke <[email protected]> (v1)