xref: /netbsd-src/lib/libpthread/arch/ia64/pthread_md.h (revision f89f6560d453f5e37386cc7938c072d2f528b9fa)
1*f89f6560Smartin /*	$NetBSD: pthread_md.h,v 1.1 2015/04/17 13:14:19 martin Exp $	*/
2*f89f6560Smartin 
3*f89f6560Smartin /*-
4*f89f6560Smartin  * Copyright (c) 2001 The NetBSD Foundation, Inc.
5*f89f6560Smartin  * All rights reserved.
6*f89f6560Smartin  *
7*f89f6560Smartin  * This code is derived from software contributed to The NetBSD Foundation
8*f89f6560Smartin  * by Nathan J. Williams.
9*f89f6560Smartin  *
10*f89f6560Smartin  * Redistribution and use in source and binary forms, with or without
11*f89f6560Smartin  * modification, are permitted provided that the following conditions
12*f89f6560Smartin  * are met:
13*f89f6560Smartin  * 1. Redistributions of source code must retain the above copyright
14*f89f6560Smartin  *    notice, this list of conditions and the following disclaimer.
15*f89f6560Smartin  * 2. Redistributions in binary form must reproduce the above copyright
16*f89f6560Smartin  *    notice, this list of conditions and the following disclaimer in the
17*f89f6560Smartin  *    documentation and/or other materials provided with the distribution.
18*f89f6560Smartin  *
19*f89f6560Smartin  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
20*f89f6560Smartin  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
21*f89f6560Smartin  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
22*f89f6560Smartin  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
23*f89f6560Smartin  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24*f89f6560Smartin  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25*f89f6560Smartin  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26*f89f6560Smartin  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27*f89f6560Smartin  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28*f89f6560Smartin  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29*f89f6560Smartin  * POSSIBILITY OF SUCH DAMAGE.
30*f89f6560Smartin  */
31*f89f6560Smartin 
32*f89f6560Smartin #ifndef _LIB_PTHREAD_IA64_MD_H
33*f89f6560Smartin #define _LIB_PTHREAD_IA64_MD_H
34*f89f6560Smartin 
35*f89f6560Smartin // #define	PTHREAD__ASM_RASOPS
36*f89f6560Smartin 
37*f89f6560Smartin static inline unsigned long
pthread__sp(void)38*f89f6560Smartin pthread__sp(void)
39*f89f6560Smartin {
40*f89f6560Smartin 	return 0;
41*f89f6560Smartin }
42*f89f6560Smartin 
43*f89f6560Smartin #define pthread__uc_sp(ucp) ((ucp)->uc_mcontext.__gregs[_REG_SP])
44*f89f6560Smartin 
45*f89f6560Smartin #endif /* _LIB_PTHREAD_IA64_MD_H */
46