]> git.saurik.com Git - apple/xnu.git/blob - osfmk/mach/ppc/machine_types.defs
0743ba1500e24d5812137b68628c08e2bacd61e6
[apple/xnu.git] / osfmk / mach / ppc / machine_types.defs
1 /*
2 * Copyright (c) 2000-2003 Apple Computer, Inc. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
6 * Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved.
7 *
8 * This file contains Original Code and/or Modifications of Original Code
9 * as defined in and that are subject to the Apple Public Source License
10 * Version 2.0 (the 'License'). You may not use this file except in
11 * compliance with the License. Please obtain a copy of the License at
12 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * file.
14 *
15 * The Original Code and all software distributed under the License are
16 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
17 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
18 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
20 * Please see the License for the specific language governing rights and
21 * limitations under the License.
22 *
23 * @APPLE_LICENSE_HEADER_END@
24 */
25 /*
26 * @OSF_COPYRIGHT@
27 */
28 /*
29 * Header file for basic, machine-dependent data types. i386 version.
30 */
31
32 #ifndef _MACHINE_VM_TYPES_DEFS_
33 #define _MACHINE_VM_TYPES_DEFS_ 1
34
35 type short = int16_t;
36 type int = int32_t;
37 type unsigned = uint32_t;
38
39 type float = MACH_MSG_TYPE_REAL_32;
40 type double = MACH_MSG_TYPE_REAL_64;
41
42
43 /* from ISO/IEC 988:1999 spec */
44 /* 7.18.1.4 Integer types capable of hgolding object pointers */
45 /*
46 * The [u]intptr_t types for the native
47 * integer type, e.g. 32 or 64 or.. whatever
48 * register size the machine has. They are
49 * used for entities that might be either
50 * [unsigned] integers or pointers, and for
51 * type-casting between the two.
52 *
53 * For instance, the IPC system represents
54 * a port in user space as an integer and
55 * in kernel space as a pointer.
56 */
57 type uintptr_t = uint32_t;
58 type intptr_t = int32_t;
59
60 /*
61 * These are the legacy Mach types that are
62 * the [rough] equivalents of the standards above.
63 * They were defined in terms of int, not
64 * long int, so they remain separate.
65 */
66 type integer_t = int32_t;
67 type natural_t = uint32_t;
68 type register_t = int32_t;
69
70
71 #if MACH_IPC_COMPAT
72 /*
73 * For the old IPC interface
74 */
75 #define MSG_TYPE_PORT_NAME natural_t
76
77 #endif /* MACH_IPC_COMPAT */
78
79
80 #endif /* _MACHINE_VM_TYPES_DEFS_ */