mesa: Add functions for doing unlocked hash table lookups
authorFredrik Höglund <fredrik@kde.org>
Wed, 13 Nov 2013 17:46:03 +0000 (18:46 +0100)
committerFredrik Höglund <fredrik@kde.org>
Fri, 2 May 2014 00:53:25 +0000 (02:53 +0200)
commit82291f64e378825e1c716742fc215db99fc8cbb2
treea4ad9d2bd807e52489808a6d4eba69eaa43f1410
parent30af8ce3f807f8a4990fa8c750038b1f75e5154f
mesa: Add functions for doing unlocked hash table lookups

This patch adds functions for locking/unlocking the mutex, along with
_mesa_HashLookupLocked() and _mesa_HashInsertLocked()
that do lookups and insertions without locking the mutex.

These functions will be used by the ARB_multi_bind entry points to
avoid locking/unlocking the mutex for each binding point.

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/mesa/main/hash.c
src/mesa/main/hash.h