From 22b6b1a4cfc84b33797eb55466afb863d4dc8b82 Mon Sep 17 00:00:00 2001 From: davidxu Date: Thu, 7 Apr 2005 06:09:17 +0000 Subject: Adjust hash function for smaller pthread structure size. --- lib/libthr/thread/thr_list.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/libthr/thread/thr_list.c b/lib/libthr/thread/thr_list.c index 6fb228b..06d14e8 100644 --- a/lib/libthr/thread/thr_list.c +++ b/lib/libthr/thread/thr_list.c @@ -65,7 +65,7 @@ static int inited = 0; LIST_HEAD(thread_hash_head, pthread); #define HASH_QUEUES 128 static struct thread_hash_head thr_hashtable[HASH_QUEUES]; -#define THREAD_HASH(thrd) (((unsigned long)thrd >> 12) % HASH_QUEUES) +#define THREAD_HASH(thrd) (((unsigned long)thrd >> 8) % HASH_QUEUES) static void thr_destroy(struct pthread *curthread, struct pthread *thread); -- cgit v1.1