1: /*
2: This is a generic file for 32-bit machines with IEEE FP arithmetic (no VMS).
3: It only supports indirect threading.
4:
5: Copyright (C) 1995,1998,1999 Free Software Foundation, Inc.
6:
7: This file is part of Gforth.
8:
9: Gforth is free software; you can redistribute it and/or
10: modify it under the terms of the GNU General Public License
11: as published by the Free Software Foundation; either version 2
12: of the License, or (at your option) any later version.
13:
14: This program is distributed in the hope that it will be useful,
15: but WITHOUT ANY WARRANTY; without even the implied warranty of
16: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17: GNU General Public License for more details.
18:
19: You should have received a copy of the GNU General Public License
20: along with this program; if not, write to the Free Software
21: Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
22: */
23:
24: #ifndef THREADING_SCHEME
25: #define THREADING_SCHEME 6
26: #endif
27:
28: #ifdef GFORTH_DEBUGGING
29: /* schedule the ip update after the rest of the primitive;
30: never mind speed */
31: #undef THREADING_SCHEME
32: #ifdef DIRECT_THREADED
33: #define THREADING_SCHEME 10
34: #else
35: #define THREADING_SCHEME 8
36: #endif /* DIRECT_THREADED */
37: #endif /* GFORTH_DEBUGGING */
38:
39:
40: /* define SYSCALL */
41:
42: #ifndef SYSCALL
43: #define SYSCALL
44: #endif
45:
46: #ifndef SYSSIGNALS
47: #define SYSSIGNALS
48: #endif
49:
50: #ifndef USE_FTOS
51: #ifndef USE_NO_FTOS
52: /* keep top of FP stack in register. Since most processors have FP
53: registers and they are hardly used in gforth, this is usually a
54: good idea. The 88100 has no separate FP regs, but many general
55: purpose regs, so it should be ok */
56: #define USE_FTOS
57: #endif
58: #endif
59: /* I don't do the same for the data stack (i.e. USE_TOS), since this
60: loses on processors with few registers. USE_TOS might be defined in
61: the processor-specific files */
62:
63: #ifdef DIRECT_THREADED
64: /* If you want direct threading, write a .h file for your processor! */
65: /* We could put some stuff here that causes a compile error, but then
66: we could not use this file in the other machine.h files */
67: #endif
68:
69: /* Types: these types are used as Forth's internal types */
70:
71: /* define this if IEEE singles and doubles are available as C data types */
72: #define IEEE_FP
73:
74: /* the IEEE types are used only for loading and storing */
75: /* the IEEE double precision type */
76: typedef double DFloat;
77: /* the IEEE single precision type */
78: typedef float SFloat;
79:
80: typedef CELL_TYPE Cell;
81: typedef unsigned CELL_TYPE UCell;
82: typedef Cell Bool;
83: typedef unsigned char Char;
84: typedef double Float;
85: typedef Char *Address;
86:
87: #if defined(DOUBLY_INDIRECT)
88: typedef void **Label;
89: #else /* !defined(DOUBLY_INDIRECT) */
90: typedef void *Label;
91: #endif /* !defined(DOUBLY_INDIRECT) */
92:
93: /* feature defines */
94:
95: #define HAS_DCOMPS
96: #define HAS_FILE
97: #define HAS_FLOATING
98: #define HAS_GLOCALS
99: #define HAS_HASH
100: #define HAS_OS
101: #define HAS_XCONDS
102: #define HAS_STANDARDTHREADING
103: #define HAS_DEBUG
104: #define HAS_PEEPHOLE
105:
106: #define RELINFOBITS 8
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>