home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
rtsi.com
/
2014.01.www.rtsi.com.tar
/
www.rtsi.com
/
OS9
/
OSK
/
EFFO
/
pd3.lzh
/
SBPROLOG2.2
/
SIM
/
simdef.h
< prev
next >
Wrap
Text File
|
1991-08-10
|
3KB
|
93 lines
/************************************************************************
* *
* The SB-Prolog System *
* Copyright SUNY at Stony Brook, 1986 *
* *
************************************************************************/
/*-----------------------------------------------------------------
SB-Prolog is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY. No author or distributor
accepts responsibility to anyone for the consequences of using it
or for whether it serves any particular purpose or works at all,
unless he says so in writing. Refer to the SB-Prolog General Public
License for full details.
Everyone is granted permission to copy, modify and redistribute
SB-Prolog, but only under the conditions described in the
SB-Prolog General Public License. A copy of this license is
supposed to have been given to you along with SB-Prolog so you
can know your rights and responsibilities. It should be in a
file named COPYING. Among other things, the copyright notice
and this notice must be preserved on all copies.
------------------------------------------------------------------ */
/* simdef.h */
#include "sim.h"
word *memory; /* heap, local stack */
word *pspace; /* psc records, instructions, p-names */
word *tstack; /* trail stack */
word reg[maxregs]; /* registers */
word psw; /* processor status word: currently (2/87) only
the lowest bit is used: a value of 0 indicates
that the last arithmetic operation resulted in
an integer value, while a value of 1 indicates
a floating-point result. */
byte *(trap_vector[maxtraps]);
word *hash_table[bucket_chain][2];
word *local_bottom;
word *heap_bottom;
word *trail_bottom;
byte *curr_fence; /* ptr to next free byte in perm space */
byte *max_fence; /* ptr to last+1 free byte in perm space */
byte *inst_begin; /* ptr to the beginning of inst. array */
short int st_base; /* base of symbol table */
word *ereg; /* last activation record */
word *breg; /* last choice point */
word *hreg; /* top of heap */
word *trreg; /* top of trail stack */
word *hbreg; /* heap back track point */
word *sreg; /* current build or unify field */
byte *cpreg; /* return point register */
byte *pcreg; /* program counter */
word oprnd1, oprnd2, oprnd3;
byte flag; /* read/write mode flag */
word flags[10]; /* pars from command line: -uI Value (Index 0-9) */
byte trace; /* (0) 1 = trace on, 0 = trace off */
byte hitrace; /* (1) 1 = hitrace on, 0 = hitrace off */
byte overflow_f = 0; /* (2) 1 = ignore stack overflow */
byte disassem;
byte trace_sta; /* 1 = keep max stack size stats */
byte call_intercept; /* hitrace or trace_sta for efficiency */
int num_line; /* print instruction addresses on trace and disassem */
word term ; /* defined in "unsafe.c" ?? */
int pcstop; /* used in "dis.c" ?? */
word nil_sym, list_str;
struct psc_rec *list_psc;
struct psc_rec *interrupt_psc;
struct psc_rec *comma_psc;
int pspace_used; /* heap_used, stack_used, trail_used; */
pw mheaptop, mlocaltop, mtrailtop;
byte *sav_pcreg, *sav_ereg; /* to save old values of pcreg and ereg to handle
saving of Prolog states correctly */
int interrupt_code;