summaryrefslogtreecommitdiff
path: root/tool/headers/mach
diff options
context:
space:
mode:
Diffstat (limited to 'tool/headers/mach')
-rw-r--r--tool/headers/mach/arm/boolean.h7
-rw-r--r--tool/headers/mach/arm/exception.h129
-rw-r--r--tool/headers/mach/arm/kern_return.h68
-rw-r--r--tool/headers/mach/arm/processor_info.h31
-rw-r--r--tool/headers/mach/arm/rpc.h30
-rw-r--r--tool/headers/mach/arm/task.h1491
-rw-r--r--tool/headers/mach/arm/thread_act.h1155
-rw-r--r--tool/headers/mach/arm/thread_state.h34
-rw-r--r--tool/headers/mach/arm/thread_status.h41
-rw-r--r--tool/headers/mach/arm/vm_param.h128
-rw-r--r--tool/headers/mach/arm/vm_types.h20
-rw-r--r--tool/headers/mach/task.h40
-rw-r--r--tool/headers/mach/thread_act.h40
13 files changed, 3214 insertions, 0 deletions
diff --git a/tool/headers/mach/arm/boolean.h b/tool/headers/mach/arm/boolean.h
new file mode 100644
index 000000000..407fe8980
--- /dev/null
+++ b/tool/headers/mach/arm/boolean.h
@@ -0,0 +1,7 @@
+#ifndef _MACH_ARM_BOOLEAN_H_
+#define _MACH_ARM_BOOLEAN_H_
+
+typedef int boolean_t;
+
+#endif
+
diff --git a/tool/headers/mach/arm/exception.h b/tool/headers/mach/arm/exception.h
new file mode 100644
index 000000000..139da8203
--- /dev/null
+++ b/tool/headers/mach/arm/exception.h
@@ -0,0 +1,129 @@
+/*
+ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * @OSF_COPYRIGHT@
+ */
+/*
+ * Mach Operating System
+ * Copyright (c) 1991,1990,1989,1988 Carnegie Mellon University
+ * All Rights Reserved.
+ *
+ * Permission to use, copy, modify and distribute this software and its
+ * documentation is hereby granted, provided that both the copyright
+ * notice and this permission notice appear in all copies of the
+ * software, derivative works or modified versions, and any portions
+ * thereof, and that both notices appear in supporting documentation.
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
+ * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
+ * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
+ *
+ * Carnegie Mellon requests users of this software to return to
+ *
+ * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
+ * School of Computer Science
+ * Carnegie Mellon University
+ * Pittsburgh PA 15213-3890
+ *
+ * any improvements or extensions that they make and grant Carnegie Mellon
+ * the rights to redistribute these changes.
+ */
+/*
+ */
+
+#ifndef _MACH_ARM_EXCEPTION_H_
+#define _MACH_ARM_EXCEPTION_H_
+
+/*
+ * No machine dependent types for the 80386
+ */
+
+#define EXC_TYPES_COUNT 10 /* incl. illegal exception 0 */
+
+/*
+ * Codes and subcodes for 80386 exceptions.
+ */
+
+#define EXCEPTION_CODE_MAX 2 /* currently code and subcode */
+
+/*
+ * EXC_BAD_INSTRUCTION
+ */
+
+#define EXC_I386_INVOP 1
+
+/*
+ * EXC_ARITHMETIC
+ */
+
+#define EXC_I386_DIV 1
+#define EXC_I386_INTO 2
+#define EXC_I386_NOEXT 3
+#define EXC_I386_EXTOVR 4
+#define EXC_I386_EXTERR 5
+#define EXC_I386_EMERR 6
+#define EXC_I386_BOUND 7
+#define EXC_I386_SSEEXTERR 8
+
+/*
+ * EXC_SOFTWARE
+ * Note: 0x10000-0x10003 in use for unix signal
+ */
+
+/*
+ * EXC_BAD_ACCESS
+ */
+
+/*
+ * EXC_BREAKPOINT
+ */
+
+#define EXC_I386_SGL 1
+#define EXC_I386_BPT 2
+
+#define EXC_I386_DIVERR 0 /* divide by 0 eprror */
+#define EXC_I386_SGLSTP 1 /* single step */
+#define EXC_I386_NMIFLT 2 /* NMI */
+#define EXC_I386_BPTFLT 3 /* breakpoint fault */
+#define EXC_I386_INTOFLT 4 /* INTO overflow fault */
+#define EXC_I386_BOUNDFLT 5 /* BOUND instruction fault */
+#define EXC_I386_INVOPFLT 6 /* invalid opcode fault */
+#define EXC_I386_NOEXTFLT 7 /* extension not available fault*/
+#define EXC_I386_DBLFLT 8 /* double fault */
+#define EXC_I386_EXTOVRFLT 9 /* extension overrun fault */
+#define EXC_I386_INVTSSFLT 10 /* invalid TSS fault */
+#define EXC_I386_SEGNPFLT 11 /* segment not present fault */
+#define EXC_I386_STKFLT 12 /* stack fault */
+#define EXC_I386_GPFLT 13 /* general protection fault */
+#define EXC_I386_PGFLT 14 /* page fault */
+#define EXC_I386_EXTERRFLT 16 /* extension error fault */
+#define EXC_I386_ALIGNFLT 17 /* Alignment fault */
+#define EXC_I386_ENDPERR 33 /* emulated extension error flt */
+#define EXC_I386_ENOEXTFLT 32 /* emulated ext not present */
+
+
+/*
+ * machine dependent exception masks
+ */
+#define EXC_MASK_MACHINE 0
+
+#endif /* _MACH_ARM_EXCEPTION_H_ */
diff --git a/tool/headers/mach/arm/kern_return.h b/tool/headers/mach/arm/kern_return.h
new file mode 100644
index 000000000..b90366e69
--- /dev/null
+++ b/tool/headers/mach/arm/kern_return.h
@@ -0,0 +1,68 @@
+/*
+ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * @OSF_COPYRIGHT@
+ */
+/*
+ * Mach Operating System
+ * Copyright (c) 1991,1990,1989 Carnegie Mellon University
+ * All Rights Reserved.
+ *
+ * Permission to use, copy, modify and distribute this software and its
+ * documentation is hereby granted, provided that both the copyright
+ * notice and this permission notice appear in all copies of the
+ * software, derivative works or modified versions, and any portions
+ * thereof, and that both notices appear in supporting documentation.
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
+ * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
+ * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
+ *
+ * Carnegie Mellon requests users of this software to return to
+ *
+ * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
+ * School of Computer Science
+ * Carnegie Mellon University
+ * Pittsburgh PA 15213-3890
+ *
+ * any improvements or extensions that they make and grant Carnegie Mellon
+ * the rights to redistribute these changes.
+ */
+/*
+ */
+
+/*
+ * File: kern_return.h
+ * Author: Avadis Tevanian, Jr., Michael Wayne Young
+ * Date: 1985
+ *
+ * Machine-dependent kernel return definitions.
+ */
+
+#ifndef _MACH_ARM_KERN_RETURN_H_
+#define _MACH_ARM_KERN_RETURN_H_
+
+#ifndef ASSEMBLER
+typedef int kern_return_t;
+#endif /* ASSEMBLER */
+
+#endif /* _MACH_ARM_KERN_RETURN_H_ */
diff --git a/tool/headers/mach/arm/processor_info.h b/tool/headers/mach/arm/processor_info.h
new file mode 100644
index 000000000..e799be9ba
--- /dev/null
+++ b/tool/headers/mach/arm/processor_info.h
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * File: mach/arm/processor_info.h
+ *
+ * Data structure definitions for ARM specific processor control
+ */
+
+#ifndef _MACH_ARM_PROCESSOR_INFO_H_
+#define _MACH_ARM_PROCESSOR_INFO_H_
+
+#endif /* _MACH_ARM_PROCESSOR_INFO_H_ */
diff --git a/tool/headers/mach/arm/rpc.h b/tool/headers/mach/arm/rpc.h
new file mode 100644
index 000000000..f72ca03ff
--- /dev/null
+++ b/tool/headers/mach/arm/rpc.h
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2002,2000 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * @OSF_COPYRIGHT@
+ */
+
+#ifndef _MACH_ARM_RPC_H_
+#define _MACH_ARM_RPC_H_
+
+#endif /* _MACH_ARM_RPC_H_ */
+
diff --git a/tool/headers/mach/arm/task.h b/tool/headers/mach/arm/task.h
new file mode 100644
index 000000000..8bc5a2ff2
--- /dev/null
+++ b/tool/headers/mach/arm/task.h
@@ -0,0 +1,1491 @@
+#ifndef _task_user_
+#define _task_user_
+
+/* Module task */
+
+#include <string.h>
+#include <mach/ndr.h>
+#include <mach/boolean.h>
+#include <mach/kern_return.h>
+#include <mach/notify.h>
+#include <mach/mach_types.h>
+#include <mach/message.h>
+#include <mach/mig_errors.h>
+#include <mach/port.h>
+
+#ifdef AUTOTEST
+#ifndef FUNCTION_PTR_T
+#define FUNCTION_PTR_T
+typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t);
+typedef struct {
+ char *name;
+ function_ptr_t function;
+} function_table_entry;
+typedef function_table_entry *function_table_t;
+#endif /* FUNCTION_PTR_T */
+#endif /* AUTOTEST */
+
+#ifndef task_MSG_COUNT
+#define task_MSG_COUNT 33
+#endif /* task_MSG_COUNT */
+
+#include <mach/std_types.h>
+#include <mach/mig.h>
+#include <mach/mig.h>
+#include <mach/mach_types.h>
+
+#ifdef __BeforeMigUserHeader
+__BeforeMigUserHeader
+#endif /* __BeforeMigUserHeader */
+
+#include <sys/cdefs.h>
+__BEGIN_DECLS
+
+
+/* Routine task_create */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_create
+(
+ task_t target_task,
+ ledger_array_t ledgers,
+ mach_msg_type_number_t ledgersCnt,
+ boolean_t inherit_memory,
+ task_t *child_task
+);
+
+/* Routine task_terminate */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_terminate
+(
+ task_t target_task
+);
+
+/* Routine task_threads */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_threads
+(
+ task_t target_task,
+ thread_act_array_t *act_list,
+ mach_msg_type_number_t *act_listCnt
+);
+
+/* Routine mach_ports_register */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t mach_ports_register
+(
+ task_t target_task,
+ mach_port_array_t init_port_set,
+ mach_msg_type_number_t init_port_setCnt
+);
+
+/* Routine mach_ports_lookup */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t mach_ports_lookup
+(
+ task_t target_task,
+ mach_port_array_t *init_port_set,
+ mach_msg_type_number_t *init_port_setCnt
+);
+
+/* Routine task_info */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_info
+(
+ task_name_t target_task,
+ task_flavor_t flavor,
+ task_info_t task_info_out,
+ mach_msg_type_number_t *task_info_outCnt
+);
+
+/* Routine task_set_info */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_info
+(
+ task_t target_task,
+ task_flavor_t flavor,
+ task_info_t task_info_in,
+ mach_msg_type_number_t task_info_inCnt
+);
+
+/* Routine task_suspend */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_suspend
+(
+ task_t target_task
+);
+
+/* Routine task_resume */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_resume
+(
+ task_t target_task
+);
+
+/* Routine task_get_special_port */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_get_special_port
+(
+ task_t task,
+ int which_port,
+ mach_port_t *special_port
+);
+
+/* Routine task_set_special_port */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_special_port
+(
+ task_t task,
+ int which_port,
+ mach_port_t special_port
+);
+
+/* Routine thread_create */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_create
+(
+ task_t parent_task,
+ thread_act_t *child_act
+);
+
+/* Routine thread_create_running */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_create_running
+(
+ task_t parent_task,
+ thread_state_flavor_t flavor,
+ thread_state_t new_state,
+ mach_msg_type_number_t new_stateCnt,
+ thread_act_t *child_act
+);
+
+/* Routine task_set_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_exception_ports
+(
+ task_t task,
+ exception_mask_t exception_mask,
+ mach_port_t new_port,
+ exception_behavior_t behavior,
+ thread_state_flavor_t new_flavor
+);
+
+/* Routine task_get_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_get_exception_ports
+(
+ task_t task,
+ exception_mask_t exception_mask,
+ exception_mask_array_t masks,
+ mach_msg_type_number_t *masksCnt,
+ exception_handler_array_t old_handlers,
+ exception_behavior_array_t old_behaviors,
+ exception_flavor_array_t old_flavors
+);
+
+/* Routine task_swap_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_swap_exception_ports
+(
+ task_t task,
+ exception_mask_t exception_mask,
+ mach_port_t new_port,
+ exception_behavior_t behavior,
+ thread_state_flavor_t new_flavor,
+ exception_mask_array_t masks,
+ mach_msg_type_number_t *masksCnt,
+ exception_handler_array_t old_handlerss,
+ exception_behavior_array_t old_behaviors,
+ exception_flavor_array_t old_flavors
+);
+
+/* Routine lock_set_create */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t lock_set_create
+(
+ task_t task,
+ lock_set_t *new_lock_set,
+ int n_ulocks,
+ int policy
+);
+
+/* Routine lock_set_destroy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t lock_set_destroy
+(
+ task_t task,
+ lock_set_t lock_set
+);
+
+/* Routine semaphore_create */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t semaphore_create
+(
+ task_t task,
+ semaphore_t *semaphore,
+ int policy,
+ int value
+);
+
+/* Routine semaphore_destroy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t semaphore_destroy
+(
+ task_t task,
+ semaphore_t semaphore
+);
+
+/* Routine task_policy_set */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_policy_set
+(
+ task_t task,
+ task_policy_flavor_t flavor,
+ task_policy_t policy_info,
+ mach_msg_type_number_t policy_infoCnt
+);
+
+/* Routine task_policy_get */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_policy_get
+(
+ task_t task,
+ task_policy_flavor_t flavor,
+ task_policy_t policy_info,
+ mach_msg_type_number_t *policy_infoCnt,
+ boolean_t *get_default
+);
+
+/* Routine task_sample */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_sample
+(
+ task_t task,
+ mach_port_t reply
+);
+
+/* Routine task_policy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_policy
+(
+ task_t task,
+ policy_t policy,
+ policy_base_t base,
+ mach_msg_type_number_t baseCnt,
+ boolean_t set_limit,
+ boolean_t change
+);
+
+/* Routine task_set_emulation */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_emulation
+(
+ task_t target_port,
+ vm_address_t routine_entry_pt,
+ int routine_number
+);
+
+/* Routine task_get_emulation_vector */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_get_emulation_vector
+(
+ task_t task,
+ int *vector_start,
+ emulation_vector_t *emulation_vector,
+ mach_msg_type_number_t *emulation_vectorCnt
+);
+
+/* Routine task_set_emulation_vector */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_emulation_vector
+(
+ task_t task,
+ int vector_start,
+ emulation_vector_t emulation_vector,
+ mach_msg_type_number_t emulation_vectorCnt
+);
+
+/* Routine task_set_ras_pc */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_ras_pc
+(
+ task_t target_task,
+ vm_address_t basepc,
+ vm_address_t boundspc
+);
+
+/* Routine task_assign */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_assign
+(
+ task_t task,
+ processor_set_t new_set,
+ boolean_t assign_threads
+);
+
+/* Routine task_assign_default */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_assign_default
+(
+ task_t task,
+ boolean_t assign_threads
+);
+
+/* Routine task_get_assignment */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_get_assignment
+(
+ task_t task,
+ processor_set_name_t *assigned_set
+);
+
+/* Routine task_set_policy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t task_set_policy
+(
+ task_t task,
+ processor_set_t pset,
+ policy_t policy,
+ policy_base_t base,
+ mach_msg_type_number_t baseCnt,
+ policy_limit_t limit,
+ mach_msg_type_number_t limitCnt,
+ boolean_t change
+);
+
+__END_DECLS
+
+/********************** Caution **************************/
+/* The following data types should be used to calculate */
+/* maximum message sizes only. The actual message may be */
+/* smaller, and the position of the arguments within the */
+/* message layout may vary from what is presented here. */
+/* For example, if any of the arguments are variable- */
+/* sized, and less than the maximum is sent, the data */
+/* will be packed tight in the actual message to reduce */
+/* the presence of holes. */
+/********************** Caution **************************/
+
+/* typedefs for all requests */
+
+#ifndef __Request__task_subsystem__defined
+#define __Request__task_subsystem__defined
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_ports_descriptor_t ledgers;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t ledgersCnt;
+ boolean_t inherit_memory;
+ } __Request__task_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_terminate_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_threads_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_ports_descriptor_t init_port_set;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t init_port_setCnt;
+ } __Request__mach_ports_register_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__mach_ports_lookup_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ task_flavor_t flavor;
+ mach_msg_type_number_t task_info_outCnt;
+ } __Request__task_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ task_flavor_t flavor;
+ mach_msg_type_number_t task_info_inCnt;
+ integer_t task_info_in[10];
+ } __Request__task_set_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_suspend_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_resume_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int which_port;
+ } __Request__task_get_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t special_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ int which_port;
+ } __Request__task_set_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_state_flavor_t flavor;
+ mach_msg_type_number_t new_stateCnt;
+ natural_t new_state[144];
+ } __Request__thread_create_running_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ exception_behavior_t behavior;
+ thread_state_flavor_t new_flavor;
+ } __Request__task_set_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ } __Request__task_get_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ exception_behavior_t behavior;
+ thread_state_flavor_t new_flavor;
+ } __Request__task_swap_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int n_ulocks;
+ int policy;
+ } __Request__lock_set_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t lock_set;
+ /* end of the kernel processed data */
+ } __Request__lock_set_destroy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int policy;
+ int value;
+ } __Request__semaphore_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t semaphore;
+ /* end of the kernel processed data */
+ } __Request__semaphore_destroy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ task_policy_flavor_t flavor;
+ mach_msg_type_number_t policy_infoCnt;
+ integer_t policy_info[16];
+ } __Request__task_policy_set_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ task_policy_flavor_t flavor;
+ mach_msg_type_number_t policy_infoCnt;
+ boolean_t get_default;
+ } __Request__task_policy_get_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t reply;
+ /* end of the kernel processed data */
+ } __Request__task_sample_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ policy_t policy;
+ mach_msg_type_number_t baseCnt;
+ integer_t base[5];
+ boolean_t set_limit;
+ boolean_t change;
+ } __Request__task_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ vm_address_t routine_entry_pt;
+ int routine_number;
+ } __Request__task_set_emulation_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_get_emulation_vector_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_descriptor_t emulation_vector;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ int vector_start;
+ mach_msg_type_number_t emulation_vectorCnt;
+ } __Request__task_set_emulation_vector_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ vm_address_t basepc;
+ vm_address_t boundspc;
+ } __Request__task_set_ras_pc_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_set;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ boolean_t assign_threads;
+ } __Request__task_assign_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ boolean_t assign_threads;
+ } __Request__task_assign_default_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__task_get_assignment_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t pset;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ policy_t policy;
+ mach_msg_type_number_t baseCnt;
+ integer_t base[5];
+ mach_msg_type_number_t limitCnt;
+ integer_t limit[1];
+ boolean_t change;
+ } __Request__task_set_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+#endif /* !__Request__task_subsystem__defined */
+
+/* union of all requests */
+
+#ifndef __RequestUnion__task_subsystem__defined
+#define __RequestUnion__task_subsystem__defined
+union __RequestUnion__task_subsystem {
+ __Request__task_create_t Request_task_create;
+ __Request__task_terminate_t Request_task_terminate;
+ __Request__task_threads_t Request_task_threads;
+ __Request__mach_ports_register_t Request_mach_ports_register;
+ __Request__mach_ports_lookup_t Request_mach_ports_lookup;
+ __Request__task_info_t Request_task_info;
+ __Request__task_set_info_t Request_task_set_info;
+ __Request__task_suspend_t Request_task_suspend;
+ __Request__task_resume_t Request_task_resume;
+ __Request__task_get_special_port_t Request_task_get_special_port;
+ __Request__task_set_special_port_t Request_task_set_special_port;
+ __Request__thread_create_t Request_thread_create;
+ __Request__thread_create_running_t Request_thread_create_running;
+ __Request__task_set_exception_ports_t Request_task_set_exception_ports;
+ __Request__task_get_exception_ports_t Request_task_get_exception_ports;
+ __Request__task_swap_exception_ports_t Request_task_swap_exception_ports;
+ __Request__lock_set_create_t Request_lock_set_create;
+ __Request__lock_set_destroy_t Request_lock_set_destroy;
+ __Request__semaphore_create_t Request_semaphore_create;
+ __Request__semaphore_destroy_t Request_semaphore_destroy;
+ __Request__task_policy_set_t Request_task_policy_set;
+ __Request__task_policy_get_t Request_task_policy_get;
+ __Request__task_sample_t Request_task_sample;
+ __Request__task_policy_t Request_task_policy;
+ __Request__task_set_emulation_t Request_task_set_emulation;
+ __Request__task_get_emulation_vector_t Request_task_get_emulation_vector;
+ __Request__task_set_emulation_vector_t Request_task_set_emulation_vector;
+ __Request__task_set_ras_pc_t Request_task_set_ras_pc;
+ __Request__task_assign_t Request_task_assign;
+ __Request__task_assign_default_t Request_task_assign_default;
+ __Request__task_get_assignment_t Request_task_get_assignment;
+ __Request__task_set_policy_t Request_task_set_policy;
+};
+#endif /* !__RequestUnion__task_subsystem__defined */
+/* typedefs for all replies */
+
+#ifndef __Reply__task_subsystem__defined
+#define __Reply__task_subsystem__defined
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t child_task;
+ /* end of the kernel processed data */
+ } __Reply__task_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_terminate_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_ports_descriptor_t act_list;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t act_listCnt;
+ } __Reply__task_threads_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__mach_ports_register_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_ports_descriptor_t init_port_set;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t init_port_setCnt;
+ } __Reply__mach_ports_lookup_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t task_info_outCnt;
+ integer_t task_info_out[10];
+ } __Reply__task_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_suspend_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_resume_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t special_port;
+ /* end of the kernel processed data */
+ } __Reply__task_get_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t child_act;
+ /* end of the kernel processed data */
+ } __Reply__thread_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t child_act;
+ /* end of the kernel processed data */
+ } __Reply__thread_create_running_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t old_handlers[32];
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t masksCnt;
+ exception_mask_t masks[32];
+ exception_behavior_t old_behaviors[32];
+ thread_state_flavor_t old_flavors[32];
+ } __Reply__task_get_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t old_handlerss[32];
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t masksCnt;
+ exception_mask_t masks[32];
+ exception_behavior_t old_behaviors[32];
+ thread_state_flavor_t old_flavors[32];
+ } __Reply__task_swap_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_lock_set;
+ /* end of the kernel processed data */
+ } __Reply__lock_set_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__lock_set_destroy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t semaphore;
+ /* end of the kernel processed data */
+ } __Reply__semaphore_create_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__semaphore_destroy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_policy_set_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t policy_infoCnt;
+ integer_t policy_info[16];
+ boolean_t get_default;
+ } __Reply__task_policy_get_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_sample_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_emulation_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_ool_descriptor_t emulation_vector;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ int vector_start;
+ mach_msg_type_number_t emulation_vectorCnt;
+ } __Reply__task_get_emulation_vector_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_emulation_vector_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_ras_pc_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_assign_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_assign_default_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t assigned_set;
+ /* end of the kernel processed data */
+ } __Reply__task_get_assignment_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__task_set_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+#endif /* !__Reply__task_subsystem__defined */
+
+/* union of all replies */
+
+#ifndef __ReplyUnion__task_subsystem__defined
+#define __ReplyUnion__task_subsystem__defined
+union __ReplyUnion__task_subsystem {
+ __Reply__task_create_t Reply_task_create;
+ __Reply__task_terminate_t Reply_task_terminate;
+ __Reply__task_threads_t Reply_task_threads;
+ __Reply__mach_ports_register_t Reply_mach_ports_register;
+ __Reply__mach_ports_lookup_t Reply_mach_ports_lookup;
+ __Reply__task_info_t Reply_task_info;
+ __Reply__task_set_info_t Reply_task_set_info;
+ __Reply__task_suspend_t Reply_task_suspend;
+ __Reply__task_resume_t Reply_task_resume;
+ __Reply__task_get_special_port_t Reply_task_get_special_port;
+ __Reply__task_set_special_port_t Reply_task_set_special_port;
+ __Reply__thread_create_t Reply_thread_create;
+ __Reply__thread_create_running_t Reply_thread_create_running;
+ __Reply__task_set_exception_ports_t Reply_task_set_exception_ports;
+ __Reply__task_get_exception_ports_t Reply_task_get_exception_ports;
+ __Reply__task_swap_exception_ports_t Reply_task_swap_exception_ports;
+ __Reply__lock_set_create_t Reply_lock_set_create;
+ __Reply__lock_set_destroy_t Reply_lock_set_destroy;
+ __Reply__semaphore_create_t Reply_semaphore_create;
+ __Reply__semaphore_destroy_t Reply_semaphore_destroy;
+ __Reply__task_policy_set_t Reply_task_policy_set;
+ __Reply__task_policy_get_t Reply_task_policy_get;
+ __Reply__task_sample_t Reply_task_sample;
+ __Reply__task_policy_t Reply_task_policy;
+ __Reply__task_set_emulation_t Reply_task_set_emulation;
+ __Reply__task_get_emulation_vector_t Reply_task_get_emulation_vector;
+ __Reply__task_set_emulation_vector_t Reply_task_set_emulation_vector;
+ __Reply__task_set_ras_pc_t Reply_task_set_ras_pc;
+ __Reply__task_assign_t Reply_task_assign;
+ __Reply__task_assign_default_t Reply_task_assign_default;
+ __Reply__task_get_assignment_t Reply_task_get_assignment;
+ __Reply__task_set_policy_t Reply_task_set_policy;
+};
+#endif /* !__RequestUnion__task_subsystem__defined */
+
+#ifndef subsystem_to_name_map_task
+#define subsystem_to_name_map_task \
+ { "task_create", 3400 },\
+ { "task_terminate", 3401 },\
+ { "task_threads", 3402 },\
+ { "mach_ports_register", 3403 },\
+ { "mach_ports_lookup", 3404 },\
+ { "task_info", 3405 },\
+ { "task_set_info", 3406 },\
+ { "task_suspend", 3407 },\
+ { "task_resume", 3408 },\
+ { "task_get_special_port", 3409 },\
+ { "task_set_special_port", 3410 },\
+ { "thread_create", 3411 },\
+ { "thread_create_running", 3412 },\
+ { "task_set_exception_ports", 3413 },\
+ { "task_get_exception_ports", 3414 },\
+ { "task_swap_exception_ports", 3415 },\
+ { "lock_set_create", 3416 },\
+ { "lock_set_destroy", 3417 },\
+ { "semaphore_create", 3418 },\
+ { "semaphore_destroy", 3419 },\
+ { "task_policy_set", 3420 },\
+ { "task_policy_get", 3421 },\
+ { "task_sample", 3422 },\
+ { "task_policy", 3423 },\
+ { "task_set_emulation", 3424 },\
+ { "task_get_emulation_vector", 3425 },\
+ { "task_set_emulation_vector", 3426 },\
+ { "task_set_ras_pc", 3427 },\
+ { "task_assign", 3429 },\
+ { "task_assign_default", 3430 },\
+ { "task_get_assignment", 3431 },\
+ { "task_set_policy", 3432 }
+#endif
+
+#ifdef __AfterMigUserHeader
+__AfterMigUserHeader
+#endif /* __AfterMigUserHeader */
+
+#endif /* _task_user_ */
diff --git a/tool/headers/mach/arm/thread_act.h b/tool/headers/mach/arm/thread_act.h
new file mode 100644
index 000000000..7c9dccd4b
--- /dev/null
+++ b/tool/headers/mach/arm/thread_act.h
@@ -0,0 +1,1155 @@
+#ifndef _thread_act_user_
+#define _thread_act_user_
+
+/* Module thread_act */
+
+#include <string.h>
+#include <mach/ndr.h>
+#include <mach/boolean.h>
+#include <mach/kern_return.h>
+#include <mach/notify.h>
+#include <mach/mach_types.h>
+#include <mach/message.h>
+#include <mach/mig_errors.h>
+#include <mach/port.h>
+
+#ifdef AUTOTEST
+#ifndef FUNCTION_PTR_T
+#define FUNCTION_PTR_T
+typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t);
+typedef struct {
+ char *name;
+ function_ptr_t function;
+} function_table_entry;
+typedef function_table_entry *function_table_t;
+#endif /* FUNCTION_PTR_T */
+#endif /* AUTOTEST */
+
+#ifndef thread_act_MSG_COUNT
+#define thread_act_MSG_COUNT 25
+#endif /* thread_act_MSG_COUNT */
+
+#include <mach/std_types.h>
+#include <mach/mig.h>
+#include <mach/mig.h>
+#include <mach/mach_types.h>
+
+#ifdef __BeforeMigUserHeader
+__BeforeMigUserHeader
+#endif /* __BeforeMigUserHeader */
+
+#include <sys/cdefs.h>
+__BEGIN_DECLS
+
+
+/* Routine thread_terminate */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_terminate
+(
+ thread_act_t target_act
+);
+
+/* Routine act_get_state */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t act_get_state
+(
+ thread_act_t target_act,
+ int flavor,
+ thread_state_t old_state,
+ mach_msg_type_number_t *old_stateCnt
+);
+
+/* Routine act_set_state */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t act_set_state
+(
+ thread_act_t target_act,
+ int flavor,
+ thread_state_t new_state,
+ mach_msg_type_number_t new_stateCnt
+);
+
+/* Routine thread_get_state */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_get_state
+(
+ thread_act_t target_act,
+ thread_state_flavor_t flavor,
+ thread_state_t old_state,
+ mach_msg_type_number_t *old_stateCnt
+);
+
+/* Routine thread_set_state */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_set_state
+(
+ thread_act_t target_act,
+ thread_state_flavor_t flavor,
+ thread_state_t new_state,
+ mach_msg_type_number_t new_stateCnt
+);
+
+/* Routine thread_suspend */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_suspend
+(
+ thread_act_t target_act
+);
+
+/* Routine thread_resume */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_resume
+(
+ thread_act_t target_act
+);
+
+/* Routine thread_abort */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_abort
+(
+ thread_act_t target_act
+);
+
+/* Routine thread_abort_safely */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_abort_safely
+(
+ thread_act_t target_act
+);
+
+/* Routine thread_depress_abort */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_depress_abort
+(
+ thread_act_t thread
+);
+
+/* Routine thread_get_special_port */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_get_special_port
+(
+ thread_act_t thr_act,
+ int which_port,
+ mach_port_t *special_port
+);
+
+/* Routine thread_set_special_port */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_set_special_port
+(
+ thread_act_t thr_act,
+ int which_port,
+ mach_port_t special_port
+);
+
+/* Routine thread_info */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_info
+(
+ thread_act_t target_act,
+ thread_flavor_t flavor,
+ thread_info_t thread_info_out,
+ mach_msg_type_number_t *thread_info_outCnt
+);
+
+/* Routine thread_set_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_set_exception_ports
+(
+ thread_act_t thread,
+ exception_mask_t exception_mask,
+ mach_port_t new_port,
+ exception_behavior_t behavior,
+ thread_state_flavor_t new_flavor
+);
+
+/* Routine thread_get_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_get_exception_ports
+(
+ thread_act_t thread,
+ exception_mask_t exception_mask,
+ exception_mask_array_t masks,
+ mach_msg_type_number_t *masksCnt,
+ exception_handler_array_t old_handlers,
+ exception_behavior_array_t old_behaviors,
+ exception_flavor_array_t old_flavors
+);
+
+/* Routine thread_swap_exception_ports */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_swap_exception_ports
+(
+ thread_act_t thread,
+ exception_mask_t exception_mask,
+ mach_port_t new_port,
+ exception_behavior_t behavior,
+ thread_state_flavor_t new_flavor,
+ exception_mask_array_t masks,
+ mach_msg_type_number_t *masksCnt,
+ exception_handler_array_t old_handlers,
+ exception_behavior_array_t old_behaviors,
+ exception_flavor_array_t old_flavors
+);
+
+/* Routine thread_policy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_policy
+(
+ thread_act_t thr_act,
+ policy_t policy,
+ policy_base_t base,
+ mach_msg_type_number_t baseCnt,
+ boolean_t set_limit
+);
+
+/* Routine thread_policy_set */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_policy_set
+(
+ thread_act_t thread,
+ thread_policy_flavor_t flavor,
+ thread_policy_t policy_info,
+ mach_msg_type_number_t policy_infoCnt
+);
+
+/* Routine thread_policy_get */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_policy_get
+(
+ thread_act_t thread,
+ thread_policy_flavor_t flavor,
+ thread_policy_t policy_info,
+ mach_msg_type_number_t *policy_infoCnt,
+ boolean_t *get_default
+);
+
+/* Routine thread_sample */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_sample
+(
+ thread_act_t thread,
+ mach_port_t reply
+);
+
+/* Routine etap_trace_thread */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t etap_trace_thread
+(
+ thread_act_t target_act,
+ boolean_t trace_status
+);
+
+/* Routine thread_assign */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_assign
+(
+ thread_act_t thread,
+ processor_set_t new_set
+);
+
+/* Routine thread_assign_default */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_assign_default
+(
+ thread_act_t thread
+);
+
+/* Routine thread_get_assignment */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_get_assignment
+(
+ thread_act_t thread,
+ processor_set_name_t *assigned_set
+);
+
+/* Routine thread_set_policy */
+#ifdef mig_external
+mig_external
+#else
+extern
+#endif /* mig_external */
+kern_return_t thread_set_policy
+(
+ thread_act_t thr_act,
+ processor_set_t pset,
+ policy_t policy,
+ policy_base_t base,
+ mach_msg_type_number_t baseCnt,
+ policy_limit_t limit,
+ mach_msg_type_number_t limitCnt
+);
+
+__END_DECLS
+
+/********************** Caution **************************/
+/* The following data types should be used to calculate */
+/* maximum message sizes only. The actual message may be */
+/* smaller, and the position of the arguments within the */
+/* message layout may vary from what is presented here. */
+/* For example, if any of the arguments are variable- */
+/* sized, and less than the maximum is sent, the data */
+/* will be packed tight in the actual message to reduce */
+/* the presence of holes. */
+/********************** Caution **************************/
+
+/* typedefs for all requests */
+
+#ifndef __Request__thread_act_subsystem__defined
+#define __Request__thread_act_subsystem__defined
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_terminate_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int flavor;
+ mach_msg_type_number_t old_stateCnt;
+ } __Request__act_get_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int flavor;
+ mach_msg_type_number_t new_stateCnt;
+ natural_t new_state[144];
+ } __Request__act_set_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_state_flavor_t flavor;
+ mach_msg_type_number_t old_stateCnt;
+ } __Request__thread_get_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_state_flavor_t flavor;
+ mach_msg_type_number_t new_stateCnt;
+ natural_t new_state[144];
+ } __Request__thread_set_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_suspend_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_resume_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_abort_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_abort_safely_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_depress_abort_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ int which_port;
+ } __Request__thread_get_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t special_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ int which_port;
+ } __Request__thread_set_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_flavor_t flavor;
+ mach_msg_type_number_t thread_info_outCnt;
+ } __Request__thread_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ exception_behavior_t behavior;
+ thread_state_flavor_t new_flavor;
+ } __Request__thread_set_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ } __Request__thread_get_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_port;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ exception_mask_t exception_mask;
+ exception_behavior_t behavior;
+ thread_state_flavor_t new_flavor;
+ } __Request__thread_swap_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ policy_t policy;
+ mach_msg_type_number_t baseCnt;
+ integer_t base[5];
+ boolean_t set_limit;
+ } __Request__thread_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_policy_flavor_t flavor;
+ mach_msg_type_number_t policy_infoCnt;
+ integer_t policy_info[16];
+ } __Request__thread_policy_set_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ thread_policy_flavor_t flavor;
+ mach_msg_type_number_t policy_infoCnt;
+ boolean_t get_default;
+ } __Request__thread_policy_get_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t reply;
+ /* end of the kernel processed data */
+ } __Request__thread_sample_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ boolean_t trace_status;
+ } __Request__etap_trace_thread_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t new_set;
+ /* end of the kernel processed data */
+ } __Request__thread_assign_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_assign_default_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ } __Request__thread_get_assignment_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t pset;
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ policy_t policy;
+ mach_msg_type_number_t baseCnt;
+ integer_t base[5];
+ mach_msg_type_number_t limitCnt;
+ integer_t limit[1];
+ } __Request__thread_set_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+#endif /* !__Request__thread_act_subsystem__defined */
+
+/* union of all requests */
+
+#ifndef __RequestUnion__thread_act_subsystem__defined
+#define __RequestUnion__thread_act_subsystem__defined
+union __RequestUnion__thread_act_subsystem {
+ __Request__thread_terminate_t Request_thread_terminate;
+ __Request__act_get_state_t Request_act_get_state;
+ __Request__act_set_state_t Request_act_set_state;
+ __Request__thread_get_state_t Request_thread_get_state;
+ __Request__thread_set_state_t Request_thread_set_state;
+ __Request__thread_suspend_t Request_thread_suspend;
+ __Request__thread_resume_t Request_thread_resume;
+ __Request__thread_abort_t Request_thread_abort;
+ __Request__thread_abort_safely_t Request_thread_abort_safely;
+ __Request__thread_depress_abort_t Request_thread_depress_abort;
+ __Request__thread_get_special_port_t Request_thread_get_special_port;
+ __Request__thread_set_special_port_t Request_thread_set_special_port;
+ __Request__thread_info_t Request_thread_info;
+ __Request__thread_set_exception_ports_t Request_thread_set_exception_ports;
+ __Request__thread_get_exception_ports_t Request_thread_get_exception_ports;
+ __Request__thread_swap_exception_ports_t Request_thread_swap_exception_ports;
+ __Request__thread_policy_t Request_thread_policy;
+ __Request__thread_policy_set_t Request_thread_policy_set;
+ __Request__thread_policy_get_t Request_thread_policy_get;
+ __Request__thread_sample_t Request_thread_sample;
+ __Request__etap_trace_thread_t Request_etap_trace_thread;
+ __Request__thread_assign_t Request_thread_assign;
+ __Request__thread_assign_default_t Request_thread_assign_default;
+ __Request__thread_get_assignment_t Request_thread_get_assignment;
+ __Request__thread_set_policy_t Request_thread_set_policy;
+};
+#endif /* !__RequestUnion__thread_act_subsystem__defined */
+/* typedefs for all replies */
+
+#ifndef __Reply__thread_act_subsystem__defined
+#define __Reply__thread_act_subsystem__defined
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_terminate_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t old_stateCnt;
+ natural_t old_state[144];
+ } __Reply__act_get_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__act_set_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t old_stateCnt;
+ natural_t old_state[144];
+ } __Reply__thread_get_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_set_state_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_suspend_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_resume_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_abort_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_abort_safely_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_depress_abort_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t special_port;
+ /* end of the kernel processed data */
+ } __Reply__thread_get_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_set_special_port_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t thread_info_outCnt;
+ integer_t thread_info_out[12];
+ } __Reply__thread_info_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_set_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t old_handlers[32];
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t masksCnt;
+ exception_mask_t masks[32];
+ exception_behavior_t old_behaviors[32];
+ thread_state_flavor_t old_flavors[32];
+ } __Reply__thread_get_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t old_handlers[32];
+ /* end of the kernel processed data */
+ NDR_record_t NDR;
+ mach_msg_type_number_t masksCnt;
+ exception_mask_t masks[32];
+ exception_behavior_t old_behaviors[32];
+ thread_state_flavor_t old_flavors[32];
+ } __Reply__thread_swap_exception_ports_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_policy_set_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ mach_msg_type_number_t policy_infoCnt;
+ integer_t policy_info[16];
+ boolean_t get_default;
+ } __Reply__thread_policy_get_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_sample_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__etap_trace_thread_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_assign_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_assign_default_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ /* start of the kernel processed data */
+ mach_msg_body_t msgh_body;
+ mach_msg_port_descriptor_t assigned_set;
+ /* end of the kernel processed data */
+ } __Reply__thread_get_assignment_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+
+#ifdef __MigPackStructs
+#pragma pack(4)
+#endif
+ typedef struct {
+ mach_msg_header_t Head;
+ NDR_record_t NDR;
+ kern_return_t RetCode;
+ } __Reply__thread_set_policy_t;
+#ifdef __MigPackStructs
+#pragma pack()
+#endif
+#endif /* !__Reply__thread_act_subsystem__defined */
+
+/* union of all replies */
+
+#ifndef __ReplyUnion__thread_act_subsystem__defined
+#define __ReplyUnion__thread_act_subsystem__defined
+union __ReplyUnion__thread_act_subsystem {
+ __Reply__thread_terminate_t Reply_thread_terminate;
+ __Reply__act_get_state_t Reply_act_get_state;
+ __Reply__act_set_state_t Reply_act_set_state;
+ __Reply__thread_get_state_t Reply_thread_get_state;
+ __Reply__thread_set_state_t Reply_thread_set_state;
+ __Reply__thread_suspend_t Reply_thread_suspend;
+ __Reply__thread_resume_t Reply_thread_resume;
+ __Reply__thread_abort_t Reply_thread_abort;
+ __Reply__thread_abort_safely_t Reply_thread_abort_safely;
+ __Reply__thread_depress_abort_t Reply_thread_depress_abort;
+ __Reply__thread_get_special_port_t Reply_thread_get_special_port;
+ __Reply__thread_set_special_port_t Reply_thread_set_special_port;
+ __Reply__thread_info_t Reply_thread_info;
+ __Reply__thread_set_exception_ports_t Reply_thread_set_exception_ports;
+ __Reply__thread_get_exception_ports_t Reply_thread_get_exception_ports;
+ __Reply__thread_swap_exception_ports_t Reply_thread_swap_exception_ports;
+ __Reply__thread_policy_t Reply_thread_policy;
+ __Reply__thread_policy_set_t Reply_thread_policy_set;
+ __Reply__thread_policy_get_t Reply_thread_policy_get;
+ __Reply__thread_sample_t Reply_thread_sample;
+ __Reply__etap_trace_thread_t Reply_etap_trace_thread;
+ __Reply__thread_assign_t Reply_thread_assign;
+ __Reply__thread_assign_default_t Reply_thread_assign_default;
+ __Reply__thread_get_assignment_t Reply_thread_get_assignment;
+ __Reply__thread_set_policy_t Reply_thread_set_policy;
+};
+#endif /* !__RequestUnion__thread_act_subsystem__defined */
+
+#ifndef subsystem_to_name_map_thread_act
+#define subsystem_to_name_map_thread_act \
+ { "thread_terminate", 3600 },\
+ { "act_get_state", 3601 },\
+ { "act_set_state", 3602 },\
+ { "thread_get_state", 3603 },\
+ { "thread_set_state", 3604 },\
+ { "thread_suspend", 3605 },\
+ { "thread_resume", 3606 },\
+ { "thread_abort", 3607 },\
+ { "thread_abort_safely", 3608 },\
+ { "thread_depress_abort", 3609 },\
+ { "thread_get_special_port", 3610 },\
+ { "thread_set_special_port", 3611 },\
+ { "thread_info", 3612 },\
+ { "thread_set_exception_ports", 3613 },\
+ { "thread_get_exception_ports", 3614 },\
+ { "thread_swap_exception_ports", 3615 },\
+ { "thread_policy", 3616 },\
+ { "thread_policy_set", 3617 },\
+ { "thread_policy_get", 3618 },\
+ { "thread_sample", 3619 },\
+ { "etap_trace_thread", 3620 },\
+ { "thread_assign", 3621 },\
+ { "thread_assign_default", 3622 },\
+ { "thread_get_assignment", 3623 },\
+ { "thread_set_policy", 3624 }
+#endif
+
+#ifdef __AfterMigUserHeader
+__AfterMigUserHeader
+#endif /* __AfterMigUserHeader */
+
+#endif /* _thread_act_user_ */
diff --git a/tool/headers/mach/arm/thread_state.h b/tool/headers/mach/arm/thread_state.h
new file mode 100644
index 000000000..a310b3805
--- /dev/null
+++ b/tool/headers/mach/arm/thread_state.h
@@ -0,0 +1,34 @@
+/*
+ * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * @OSF_COPYRIGHT@
+ */
+
+#ifndef _MACH_ARM_THREAD_STATE_H_
+#define _MACH_ARM_THREAD_STATE_H_
+
+/* Size of maximum exported thread state in words */
+#define ARM_THREAD_STATE_MAX (17*4) /* Size of biggest state possible */
+
+#define THREAD_STATE_MAX ARM_THREAD_STATE_MAX
+
+#endif /* _MACH_ARM_THREAD_STATE_H_ */
diff --git a/tool/headers/mach/arm/thread_status.h b/tool/headers/mach/arm/thread_status.h
new file mode 100644
index 000000000..53d2edcf7
--- /dev/null
+++ b/tool/headers/mach/arm/thread_status.h
@@ -0,0 +1,41 @@
+/* ----------------------------------------------------------------------------
+ * iphone-binutils: development tools for the Apple iPhone 07/12/2007
+ * Copyright (c) 2007 Patrick Walton <pcwalton@uchicago.edu> but freely
+ * redistributable under the terms of the GNU General Public License.
+ *
+ * mach/arm/thread_status.h: information needed to save/restore threads
+ * ------------------------------------------------------------------------- */
+
+#ifndef MACH_ARM_THREAD_STATUS_H
+#define MACH_ARM_THREAD_STATUS_H
+
+#define ARM_THREAD_STATE 1
+#define ARM_THREAD_STATE_COUNT ((mach_msg_type_number_t) \
+ ( sizeof (arm_thread_state_t) / sizeof (int) ))
+
+#define THREAD_STATE_NONE 1
+
+struct arm_thread_state {
+ unsigned int r0;
+ unsigned int r1;
+ unsigned int r2;
+ unsigned int r3;
+ unsigned int r4;
+ unsigned int r5;
+ unsigned int r6;
+ unsigned int r7;
+ unsigned int r8;
+ unsigned int r9;
+ unsigned int r10;
+ unsigned int r11;
+ unsigned int r12;
+ unsigned int r13;
+ unsigned int r14;
+ unsigned int r15;
+ unsigned int r16; /* Apple's thread_state has this 17th reg, bug?? */
+};
+
+typedef struct arm_thread_state arm_thread_state_t;
+
+#endif
+
diff --git a/tool/headers/mach/arm/vm_param.h b/tool/headers/mach/arm/vm_param.h
new file mode 100644
index 000000000..1f0a07a98
--- /dev/null
+++ b/tool/headers/mach/arm/vm_param.h
@@ -0,0 +1,128 @@
+/*
+ * Copyright (c) 2000-2004 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_LICENSE_HEADER_START@
+ *
+ * The contents of this file constitute Original Code as defined in and
+ * are subject to the Apple Public Source License Version 1.1 (the
+ * "License"). You may not use this file except in compliance with the
+ * License. Please obtain a copy of the License at
+ * http://www.apple.com/publicsource and read it before using this file.
+ *
+ * This Original Code and all software distributed under the License are
+ * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
+ * License for the specific language governing rights and limitations
+ * under the License.
+ *
+ * @APPLE_LICENSE_HEADER_END@
+ */
+/*
+ * @OSF_COPYRIGHT@
+ */
+/*
+ * Mach Operating System
+ * Copyright (c) 1991,1990,1989,1988 Carnegie Mellon University
+ * All Rights Reserved.
+ *
+ * Permission to use, copy, modify and distribute this software and its
+ * documentation is hereby granted, provided that both the copyright
+ * notice and this permission notice appear in all copies of the
+ * software, derivative works or modified versions, and any portions
+ * thereof, and that both notices appear in supporting documentation.
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
+ * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
+ * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
+ *
+ * Carnegie Mellon requests users of this software to return to
+ *
+ * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
+ * School of Computer Science
+ * Carnegie Mellon University
+ * Pittsburgh PA 15213-3890
+ *
+ * any improvements or extensions that they make and grant Carnegie Mellon
+ * the rights to redistribute these changes.
+ */
+
+/*
+ * Copyright (c) 1994 The University of Utah and
+ * the Computer Systems Laboratory at the University of Utah (CSL).
+ * All rights reserved.
+ *
+ * Permission to use, copy, modify and distribute this software is hereby
+ * granted provided that (1) source code retains these copyright, permission,
+ * and disclaimer notices, and (2) redistributions including binaries
+ * reproduce the notices in supporting documentation, and (3) all advertising
+ * materials mentioning features or use of this software display the following
+ * acknowledgement: ``This product includes software developed by the
+ * Computer Systems Laboratory at the University of Utah.''
+ *
+ * THE UNIVERSITY OF UTAH AND CSL ALLOW FREE USE OF THIS SOFTWARE IN ITS "AS
+ * IS" CONDITION. THE UNIVERSITY OF UTAH AND CSL DISCLAIM ANY LIABILITY OF
+ * ANY KIND FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
+ *
+ * CSL requests users of this software to return to csl-dist@cs.utah.edu any
+ * improvements that they make and grant CSL redistribution rights.
+ *
+ */
+
+/*
+ * File: vm_param.h
+ *
+ * ARM machine dependent virtual memory parameters.
+ * Most of the declarations are preceeded by ARM_ (or arm_)
+ * which is OK because only ARM specific code will be using
+ * them.
+ */
+
+#ifndef _MACH_ARM_VM_PARAM_H_
+#define _MACH_ARM_VM_PARAM_H_
+
+#define BYTE_SIZE 8 /* byte size in bits */
+
+/* FIXME: is this right? */
+#define ARM_PGBYTES 4096 /* bytes per 80386 page */
+#define ARM_PGSHIFT 12 /* number of bits to shift for pages */
+
+#define PAGE_SIZE ARM_PGBYTES
+#define PAGE_SHIFT ARM_PGSHIFT
+#define PAGE_MASK (PAGE_SIZE - 1)
+
+
+
+#define VM_MIN_ADDRESS64 ((user_addr_t) 0x0000000000000000ULL)
+/*
+ * default top of user stack... it grows down from here
+ */
+#define VM_USRSTACK64 ((user_addr_t) 0x00007FFF5FC00000ULL)
+#define VM_DYLD64 ((user_addr_t) 0x00007FFF5FC00000ULL)
+#define VM_LIB64_SHR_DATA ((user_addr_t) 0x00007FFF60000000ULL)
+#define VM_LIB64_SHR_TEXT ((user_addr_t) 0x00007FFF80000000ULL)
+/*
+ * the end of the usable user address space , for now about 47 bits.
+ * the 64 bit commpage is past the end of this
+ */
+#define VM_MAX_PAGE_ADDRESS ((user_addr_t) 0x00007FFFFFE00000ULL)
+/*
+ * canonical end of user address space for limits checking
+ */
+#define VM_MAX_USER_PAGE_ADDRESS ((user_addr_t)0x00007FFFFFFFF000ULL)
+
+
+
+/* system-wide values */
+#define MACH_VM_MIN_ADDRESS ((mach_vm_offset_t) 0)
+#define MACH_VM_MAX_ADDRESS ((mach_vm_offset_t) VM_MAX_PAGE_ADDRESS)
+
+/* process-relative values (all 32-bit legacy only for now) */
+#define VM_MIN_ADDRESS ((vm_offset_t) 0)
+#define VM_USRSTACK32 ((vm_offset_t) 0xC0000000)
+#define VM_MAX_ADDRESS ((vm_offset_t) 0xFFE00000)
+
+
+#endif /* _MACH_ARM_VM_PARAM_H_ */
+
diff --git a/tool/headers/mach/arm/vm_types.h b/tool/headers/mach/arm/vm_types.h
new file mode 100644
index 000000000..7b2eac30b
--- /dev/null
+++ b/tool/headers/mach/arm/vm_types.h
@@ -0,0 +1,20 @@
+#ifndef _MACH_ARM_VM_TYPES_H_
+#define _MACH_ARM_VM_TYPES_H_
+
+#include <arm/_types.h>
+#include <stdint.h>
+
+typedef __darwin_natural_t natural_t;
+typedef int integer_t;
+
+typedef natural_t vm_offset_t;
+typedef natural_t vm_size_t;
+
+typedef uint64_t mach_vm_address_t;
+typedef uint64_t mach_vm_offset_t;
+typedef uint64_t mach_vm_size_t;
+
+#define MACH_MSG_TYPE_INTEGER_T MACH_MSG_TYPE_INTEGER_32
+
+#endif
+
diff --git a/tool/headers/mach/task.h b/tool/headers/mach/task.h
new file mode 100644
index 000000000..459a33009
--- /dev/null
+++ b/tool/headers/mach/task.h
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
+ *
+ * This file contains Original Code and/or Modifications of Original Code
+ * as defined in and that are subject to the Apple Public Source License
+ * Version 2.0 (the 'License'). You may not use this file except in
+ * compliance with the License. The rights granted to you under the License
+ * may not be used to create, or enable the creation or redistribution of,
+ * unlawful or unlicensed copies of an Apple operating system, or to
+ * circumvent, violate, or enable the circumvention or violation of, any
+ * terms of an Apple operating system software license agreement.
+ *
+ * Please obtain a copy of the License at
+ * http://www.opensource.apple.com/apsl/ and read it before using this file.
+ *
+ * The Original Code and all software distributed under the License are
+ * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+ * Please see the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
+ */
+#if defined(__i386__)
+#include <mach/i386/task.h>
+#elif defined(__x86_64__)
+#include <mach/x86_64/task.h>
+#elif defined(__ppc__)
+#include <mach/ppc/task.h>
+#elif defined(__ppc64__)
+#include <mach/ppc64/task.h>
+#elif defined(__arm__)
+#include <mach/arm/task.h>
+#else
+#error unknown architecture
+#endif
diff --git a/tool/headers/mach/thread_act.h b/tool/headers/mach/thread_act.h
new file mode 100644
index 000000000..ac2309bf6
--- /dev/null
+++ b/tool/headers/mach/thread_act.h
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
+ *
+ * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
+ *
+ * This file contains Original Code and/or Modifications of Original Code
+ * as defined in and that are subject to the Apple Public Source License
+ * Version 2.0 (the 'License'). You may not use this file except in
+ * compliance with the License. The rights granted to you under the License
+ * may not be used to create, or enable the creation or redistribution of,
+ * unlawful or unlicensed copies of an Apple operating system, or to
+ * circumvent, violate, or enable the circumvention or violation of, any
+ * terms of an Apple operating system software license agreement.
+ *
+ * Please obtain a copy of the License at
+ * http://www.opensource.apple.com/apsl/ and read it before using this file.
+ *
+ * The Original Code and all software distributed under the License are
+ * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+ * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+ * Please see the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
+ */
+#if defined(__i386__)
+#include <mach/i386/thread_act.h>
+#elif defined(__x86_64__)
+#include <mach/x86_64/thread_act.h>
+#elif defined(__ppc__)
+#include <mach/ppc/thread_act.h>
+#elif defined(__ppc64__)
+#include <mach/ppc64/thread_act.h>
+#elif defined(__arm__)
+#include <mach/arm/thread_act.h>
+#else
+#error unknown architecture
+#endif