|
|
DataMuseum.dkPresents historical artifacts from the history of: RC9000 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RC9000 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - downloadIndex: @ T p
Length: 2353 (0x931)
Types: TextFile
Notes: @(#)pcb.h 13.1 (RC Computer) 91/02/02 */
Names: »pcb.h«
└─⟦50656ff4a⟧ Bits:30010538 TX 3.1 Coldstart
└─⟦bbf173f5c⟧ »0004«
└─⟦this⟧ »./usr/include/rc/pcb.h«
/* @(#)pcb.h 13.1 (RC Computer) 91/02/02 */
/*
* RC9000 process control block
* MUST be first element of upage
*/
#ifndef _PCB_
#define _PCB_
/*
* pcb_regs indices
*/
#define PCB_S0 0 /* callee saved regs.... */
#define PCB_S1 1
#define PCB_S2 2
#define PCB_S3 3
#define PCB_S4 4
#define PCB_S5 5
#define PCB_S6 6
#define PCB_S7 7
#define PCB_SP 8 /* stack pointer */
#define PCB_FP 9 /* frame pointer */
#define PCB_PC 10 /* program counter */
#define PCB_SR 11 /* C0 status register */
#define NPCBREGS 12 /* number of regs saved at ctxt switch */
/*
* jmp_buf offsets
* WARNING:
* if this changes, label_t in types.h must change
*/
#define JB_S0 0 /* callee saved regs.... */
#define JB_S1 1
#define JB_S2 2
#define JB_S3 3
#define JB_S4 4
#define JB_S5 5
#define JB_S6 6
#define JB_S7 7
#define JB_SP 8 /* stack pointer */
#define JB_FP 9 /* frame pointer */
#define JB_PC 10 /* program counter */
#define JB_SR 11 /* C0 status register */
#define NJBREGS 12
#if defined(LANGUAGE_C)
struct pcb
{
/*
* General purpose registers saved at context switch time.
*
* NOTE: current switch assembler code assumes that pcb is first
* entry in u area, and that pcb_regs is the first thing in the
* pcb.
*/
int pcb_regs[32];
int pcb_pc;
int pcb_sr;
/*
* Misc.
*/
int *pcb_sswap; /* ptr for non-local resume */
int pcb_astpend; /* non-zero if ast-trap wanted */
/* These are use in branch delay instruction emulation */
int pcb_bd_epc; /* epc register */
int pcb_bd_cause; /* cause register */
int pcb_bd_ra; /* address to return to if doing bd emulation */
int pcb_bd_instr; /* the branch instr for the bd emulation */
/* This is use in fp instruction emulation */
int pcb_softfp_pc; /* resulting pc after fp emulation */
/*
* Space for the state of all the potential coprocessors. WASTEFUL!
*/
int pcb_fpregs[32]; /* floating point */
int pcb_fpc_csr; /* floating point control and status reg */
int pcb_fpc_eir; /* floating point exception instruction reg */
int pcb_ownedfp; /* has owned fp at one time */
int pcb_c2regs[32]; /* TBD */
int pcb_c3regs[32]; /* TBD */
};
#define aston(i) (u.u_pcb.pcb_astpend |= (i))
#define astoff(i) (u.u_pcb.pcb_astpend &= ~(i))
#endif define(LANGUAGE_C)
#define ASTSOWEUPC 0x0001
#define ASTRUNRUN 0x0002
#define ASTSIG 0x0004
#endif