Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/vax/include Add __lwp_getprivate_fast



details:   https://anonhg.NetBSD.org/src/rev/d60fe1f28896
branches:  trunk
changeset: 764155:d60fe1f28896
user:      matt <matt%NetBSD.org@localhost>
date:      Tue Apr 12 18:24:28 2011 +0000

description:
Add __lwp_getprivate_fast

diffstat:

 sys/arch/vax/include/mcontext.h |  10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diffs (22 lines):

diff -r 735e035f6ebb -r d60fe1f28896 sys/arch/vax/include/mcontext.h
--- a/sys/arch/vax/include/mcontext.h   Tue Apr 12 18:10:15 2011 +0000
+++ b/sys/arch/vax/include/mcontext.h   Tue Apr 12 18:24:28 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: mcontext.h,v 1.5 2008/04/28 20:23:39 martin Exp $      */
+/*     $NetBSD: mcontext.h,v 1.6 2011/04/12 18:24:28 matt Exp $        */
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -70,4 +70,12 @@
 
 #define        _UC_MACHINE_SET_PC(uc, pc)      _UC_MACHINE_PC(uc) = (pc)
 
+static __inline void *
+__lwp_getprivate_fast(void)
+{
+       register void *tcb __asm("r0");
+       __asm("chmu $1" ::: "r0");
+       return tcb;
+}
+
 #endif /* !_VAX_MCONTEXT_H_ */



Home | Main Index | Thread Index | Old Index