Blame sysdeps/generic/thread_state.h

Packit 6c4009
/* Mach thread state definitions for machine-independent code.  Stub version.
Packit 6c4009
   Copyright (C) 1994-2018 Free Software Foundation, Inc.
Packit 6c4009
   This file is part of the GNU C Library.
Packit 6c4009
Packit 6c4009
   The GNU C Library is free software; you can redistribute it and/or
Packit 6c4009
   modify it under the terms of the GNU Lesser General Public
Packit 6c4009
   License as published by the Free Software Foundation; either
Packit 6c4009
   version 2.1 of the License, or (at your option) any later version.
Packit 6c4009
Packit 6c4009
   The GNU C Library is distributed in the hope that it will be useful,
Packit 6c4009
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 6c4009
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 6c4009
   Lesser General Public License for more details.
Packit 6c4009
Packit 6c4009
   You should have received a copy of the GNU Lesser General Public
Packit 6c4009
   License along with the GNU C Library; if not, see
Packit 6c4009
   <http://www.gnu.org/licenses/>.  */
Packit 6c4009
Packit 6c4009
/* Everything else is called `thread_state', but CMU's header file is
Packit 6c4009
   called `thread_status'.  Oh boy.  */
Packit 6c4009
#include <mach/thread_state.h>
Packit 6c4009
Packit 6c4009
/* Replace <machine> with "i386" or "mips" or whatever.  */
Packit 6c4009
Packit 6c4009
/* This lets the kernel define architecture-specific registers for a new
Packit 6c4009
   thread.  */
Packit 6c4009
#define MACHINE_NEW_THREAD_STATE_FLAVOR	<machine>_NEW_THREAD_STATE
Packit 6c4009
/* This makes the kernel load all architectures-specific registers for the
Packit 6c4009
   thread.  */
Packit 6c4009
#define MACHINE_THREAD_STATE_FLAVOR	<machine>_THREAD_STATE
Packit 6c4009
#define MACHINE_THREAD_STATE_COUNT	<machine>_THREAD_STATE_COUNT
Packit 6c4009
Packit 6c4009
#define machine_thread_state <machine>_thread_state
Packit 6c4009
Packit 6c4009
/* Define these to the member names in `struct <machine>_thread_state'
Packit 6c4009
   for the PC and stack pointer.  */
Packit 6c4009
#define PC ?
Packit 6c4009
#define SP ?
Packit 6c4009
Packit 6c4009
/* This structure should contain all of the different flavors of thread
Packit 6c4009
   state structures which are meaningful for this machine.  Every machine's
Packit 6c4009
   definition of this structure should have a member `int set' which is a
Packit 6c4009
   bit mask (1 << FLAVOR) of the flavors of thread state in the structure
Packit 6c4009
   which are filled in; and a member `struct machine_thread_state basic'.
Packit 6c4009
   On some machines those are the only members (e.g. i386); on others,
Packit 6c4009
   there are several relevant flavors of thread state (e.g. mips).  */
Packit 6c4009
struct machine_thread_all_state
Packit 6c4009
  {
Packit 6c4009
    int set;			/* Mask of bits (1 << FLAVOR).  */
Packit 6c4009
    struct <machine>_thread_state basic;
Packit 6c4009
  };