From: Chris Hanson Date: Wed, 20 Jun 1990 19:55:07 +0000 (+0000) Subject: * Complete redesign of the operating-system interface. I/O is more X-Git-Tag: 20090517-FFI~11378 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=65622a9508e289d36f84ea063acf0202d7a2bc79;p=mit-scheme.git * Complete redesign of the operating-system interface. I/O is more uniform and is able to take advantage of things like sockets, pipes, ptys, etc. All I/O buffering is moved into the runtime system for better performance with Scheme compiler code. Strong knowledge of POSIX.1 should make porting to VMS easy once VMS supports POSIX.1. * Change operating system conditionalizations to standard form suggested by POSIX.1. * Add FSF macros to support ANSI declarations. * Add dynamic-stack package and obstacks. * Provide higher-level utilities for parsing command line options. * Instead of `Back_To_Eval', there is now a procedure `abort_to_interpreter' which knows about everything that needs to be cleaned up. * Change names of some macros: Pop STACK_POP Push STACK_PUSH Push_From STACK_LOCATIVE_PUSH Pop_Into STACK_LOCATIVE_POP (similar) Stack_Ref STACK_REF Top_Of_Stack() STACK_REF(0) Simulate_Popping STACK_LOC Simulate_Pushing STACK_LOC (similar) Stack_Distance STACK_LOCATIVE_DIFFERENCE (similar) Pop_Primitive_Frame POP_PRIMITIVE_FRAME Metering_Apply_Primitive PRIMITIVE_APPLY Export_Regs_Before_Primitive EXPORT_REGS_BEFORE_PRIMITIVE Import_Regs_After_Primitive IMPORT_REGS_AFTER_PRIMITIVE * Sun assembler can't handle a constant used in "cmpaux-mc68k.m4", so provide an option to rewrite that instruction as two instructions. * Some compilers won't cast a function to an integer, so kludge around it by mis-declaring the external function as an integer, taking it the integer's address, and casting THAT to an integer. * Move critical section code and termination code to their own files. --- diff --git a/v7/src/microcode/m/hp9k800.h b/v7/src/microcode/m/hp9k800.h index 7124bbbd2..79159c7e0 100644 --- a/v7/src/microcode/m/hp9k800.h +++ b/v7/src/microcode/m/hp9k800.h @@ -1,7 +1,7 @@ /* -*-C-*- Machine file for HP9000 series 800 -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/hp9k800.h,v 1.4 1990/01/22 22:26:07 jinx Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/hp9k800.h,v 1.5 1990/06/20 19:54:03 cph Rel $ Copyright (c) 1989, 1990 Massachusetts Institute of Technology @@ -40,5 +40,5 @@ MIT in each case. */ #define STARBASE_DEVICE_DRIVERS -ldd98550 #endif -#define C_SWITCH_MACHINE -Dspectrum -DTYPE_CODE_LENGTH=6 +#define C_SWITCH_MACHINE -DTYPE_CODE_LENGTH=6 #define M4_SWITCH_MACHINE -DTYPE_CODE_LENGTH=6 diff --git a/v7/src/microcode/m/sun3.h b/v7/src/microcode/m/sun3.h index 5bec63785..182fb8469 100644 --- a/v7/src/microcode/m/sun3.h +++ b/v7/src/microcode/m/sun3.h @@ -1,7 +1,7 @@ /* -*-C-*- Machine file for Sun 3 -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/sun3.h,v 1.2 1990/05/08 10:20:11 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/sun3.h,v 1.3 1990/06/20 19:54:08 cph Rel $ Copyright (c) 1989, 1990 Massachusetts Institute of Technology @@ -35,8 +35,15 @@ MIT in each case. */ #define PROC_TYPE PROC_TYPE_68020 -/* Remove "-Dsun3" if you are running an older version of the operating - system. If your machine doesn't have a 68881 coprocessor, remove +#ifndef ALTERNATE_CC + +/* If your machine doesn't have a 68881 coprocessor, remove "-f68881" from this line and the LD_SWITCH_MACHINE line. */ -#define C_SWITCH_MACHINE -Dsun -Dunix -Dsun3 -f68881 -DTYPE_CODE_LENGTH=6 +#define C_SWITCH_MACHINE -Dsun3 -DTYPE_CODE_LENGTH=6 -f68881 #define LD_SWITCH_MACHINE -f68881 + +#else /* ALTERNATE_CC */ + +#define C_SWITCH_MACHINE -Dsun3 -DTYPE_CODE_LENGTH=6 + +#endif diff --git a/v7/src/microcode/m/sun4.h b/v7/src/microcode/m/sun4.h index 8b0693e95..5efc8a6e4 100644 --- a/v7/src/microcode/m/sun4.h +++ b/v7/src/microcode/m/sun4.h @@ -1,7 +1,7 @@ /* -*-C-*- Machine file for Sun 4 -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/sun4.h,v 1.1 1990/02/07 21:33:20 jinx Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/m/Attic/sun4.h,v 1.2 1990/06/20 19:54:13 cph Rel $ Copyright (c) 1990 Massachusetts Institute of Technology @@ -35,5 +35,5 @@ MIT in each case. */ #define PROC_TYPE PROC_TYPE_SPARC -#define C_SWITCH_MACHINE -Dsun -Dunix -Dsun4 +#define C_SWITCH_MACHINE -Dsun4 #define LD_SWITCH_MACHINE diff --git a/v7/src/microcode/s/bsd4-2.h b/v7/src/microcode/s/bsd4-2.h index 2cefca67e..57543ebca 100644 --- a/v7/src/microcode/s/bsd4-2.h +++ b/v7/src/microcode/s/bsd4-2.h @@ -1,7 +1,7 @@ /* -*-C-*- System file for BSD4.2 -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/bsd4-2.h,v 1.3 1989/08/02 01:03:59 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/bsd4-2.h,v 1.4 1990/06/20 19:54:52 cph Exp $ Copyright (c) 1989 Massachusetts Institute of Technology @@ -36,11 +36,8 @@ MIT in each case. */ /* This says we have curses terminal support for Edwin. */ #define HAVE_CURSES -#define C_SWITCH_SYSTEM -Dbsd +#define C_SWITCH_SYSTEM -D_BSD4_2 #define LIBS_SYSTEM -ltermcap -#define SOURCES_SYSTEM unixprim.c -#define OBJECTS_SYSTEM unixprim.o - #define ALTERNATE_M4 s/ultrix.m4 diff --git a/v7/src/microcode/s/hpux.h b/v7/src/microcode/s/hpux.h index daa96500b..b82e4b007 100644 --- a/v7/src/microcode/s/hpux.h +++ b/v7/src/microcode/s/hpux.h @@ -1,7 +1,7 @@ /* -*-C-*- System file for HP-UX -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/hpux.h,v 1.5 1990/04/17 22:20:00 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/hpux.h,v 1.6 1990/06/20 19:54:58 cph Exp $ Copyright (c) 1989, 1990 Massachusetts Institute of Technology @@ -42,9 +42,6 @@ MIT in each case. */ /* No special libraries are needed for debugging. */ #define LIB_DEBUG -#define SOURCES_SYSTEM unixprim.c -#define OBJECTS_SYSTEM unixprim.o - #ifndef HAVE_CURSES #define LIBS_SYSTEM -lcurses #endif @@ -53,9 +50,7 @@ MIT in each case. */ #define INSTALL_PROGRAM cp #endif -#ifdef ALTERNATE_CC -/* If the alternate compiler defines __STDC__ this macro must also be +/* If the compiler defines __STDC__ this macro must also be defined or the include files don't define many necessary symbols. In any case this definition does no harm. */ -#define C_SWITCH_SYSTEM -D_HPUX_SOURCE -#endif +#define C_SWITCH_SYSTEM -D_HPUX -D_HPUX_SOURCE diff --git a/v7/src/microcode/s/ultrix.h b/v7/src/microcode/s/ultrix.h index a623da092..4c69c6a36 100644 --- a/v7/src/microcode/s/ultrix.h +++ b/v7/src/microcode/s/ultrix.h @@ -1,7 +1,7 @@ /* -*-C-*- System file for Ultrix -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/ultrix.h,v 1.6 1990/04/12 21:08:14 jinx Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/ultrix.h,v 1.7 1990/06/20 19:55:03 cph Exp $ Copyright (c) 1989, 1990 Massachusetts Institute of Technology @@ -39,7 +39,7 @@ MIT in each case. */ /* This says we have curses terminal support for Edwin. */ #define HAVE_CURSES -#define C_SWITCH_SYSTEM -Dbsd -DULTRIX +#define C_SWITCH_SYSTEM -D_BSD4_2 -D_ULTRIX #define LIBS_SYSTEM -ltermcap diff --git a/v7/src/microcode/s/umax.h b/v7/src/microcode/s/umax.h index 1e5d5efe6..53e49164f 100644 --- a/v7/src/microcode/s/umax.h +++ b/v7/src/microcode/s/umax.h @@ -1,7 +1,7 @@ /* -*-C-*- System file for Encore UMAX42 and Mach -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/umax.h,v 1.1 1989/08/02 17:02:23 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/s/Attic/umax.h,v 1.2 1990/06/20 19:55:07 cph Exp $ Copyright (c) 1989 Massachusetts Institute of Technology @@ -36,9 +36,6 @@ MIT in each case. */ /* This says we have curses terminal support for Edwin. */ #define HAVE_CURSES -#define C_SWITCH_SYSTEM -Dbsd -Dumax +#define C_SWITCH_SYSTEM -D_BSD4_2 -Dumax #define LIBS_SYSTEM -ltermcap - -#define SOURCES_SYSTEM unixprim.c -#define OBJECTS_SYSTEM unixprim.o