Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libpthread Add __HAVE___LWP_GETTCB_FAST support (for mip...
details: https://anonhg.NetBSD.org/src/rev/60af1bcf691c
branches: trunk
changeset: 763309:60af1bcf691c
user: matt <matt%NetBSD.org@localhost>
date: Thu Mar 17 00:43:48 2011 +0000
description:
Add __HAVE___LWP_GETTCB_FAST support (for mips and powerpc).
diffstat:
lib/libpthread/pthread_int.h | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (22 lines):
diff -r 76d6986fdcd7 -r 60af1bcf691c lib/libpthread/pthread_int.h
--- a/lib/libpthread/pthread_int.h Wed Mar 16 23:20:00 2011 +0000
+++ b/lib/libpthread/pthread_int.h Thu Mar 17 00:43:48 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pthread_int.h,v 1.77 2011/03/16 12:39:44 joerg Exp $ */
+/* $NetBSD: pthread_int.h,v 1.78 2011/03/17 00:43:48 matt Exp $ */
/*-
* Copyright (c) 2001, 2002, 2003, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -259,7 +259,11 @@
static inline pthread_t __constfunc
pthread__self(void)
{
- struct tls_tcb *tcb = __lwp_getprivate_fast();
+#ifdef __HAVE___LWP_GETTCB_FAST
+ struct tls_tcb * const tcb = __lwp_gettcb_fast();
+#else
+ struct tls_tcb * const tcb = __lwp_getprivate_fast();
+#endif
return (pthread_t)tcb->tcb_pthread;
}
#elif 0 && defined(__HAVE___LWP_GETPRIVATE_FAST)
Home |
Main Index |
Thread Index |
Old Index