From 6dae6f96da929d0a756f6357e0921d858f0b43b6 Mon Sep 17 00:00:00 2001 From: "Guillermo J. Rozas" Date: Mon, 8 Nov 1993 06:34:30 +0000 Subject: [PATCH] Add extra fasl field for systems without HEAP_IN_LOW_MEMORY. --- v7/src/microcode/dump.c | 8 +++++++- v7/src/microcode/fasl.h | 5 +++-- v7/src/microcode/load.c | 6 ++++-- v8/src/microcode/fasl.h | 5 +++-- 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/v7/src/microcode/dump.c b/v7/src/microcode/dump.c index 718692bfe..389a74e06 100644 --- a/v7/src/microcode/dump.c +++ b/v7/src/microcode/dump.c @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: dump.c,v 9.38 1993/11/04 19:33:13 gjr Exp $ +$Id: dump.c,v 9.39 1993/11/08 06:34:18 gjr Exp $ Copyright (c) 1987-1993 Massachusetts Institute of Technology @@ -128,6 +128,12 @@ DEFUN (prepare_dump_header, (Buffer, Dumped_Object, Buffer[FASL_Offset_C_Size] = MAKE_OBJECT (TC_BROKEN_HEART, c_table_size); +#ifdef HEAP_IN_LOW_MEMORY + Buffer[FASL_Offset_Mem_Base] = ((SCHEME_OBJECT) 0); +#else /* not HEAP_IN_LOW_MEMORY */ + Buffer[FASL_Offset_Mem_Base] = ((SCHEME_OBJECT) memory_base); +#endif /* HEAP_IN_LOW_MEMORY */ + Buffer[FASL_Offset_Check_Sum] = SHARP_F; for (i = FASL_Offset_First_Free; i < FASL_HEADER_LENGTH; i++) Buffer[i] = SHARP_F; diff --git a/v7/src/microcode/fasl.h b/v7/src/microcode/fasl.h index aa53ae9d4..259404053 100644 --- a/v7/src/microcode/fasl.h +++ b/v7/src/microcode/fasl.h @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: fasl.h,v 9.34 1993/11/04 04:02:49 gjr Exp $ +$Id: fasl.h,v 9.35 1993/11/08 06:34:23 gjr Exp $ Copyright (c) 1987-1993 Massachusetts Institute of Technology @@ -60,8 +60,9 @@ MIT in each case. */ #define FASL_Offset_Check_Sum 12 /* Header and data checksum. */ #define FASL_Offset_C_Length 13 /* Number of entries in the C code table */ #define FASL_Offset_C_Size 14 /* Size of C code table in SCHEME_OBJECTs */ +#define FASL_Offset_Mem_Base 15 /* Base address when not HEAP_IN_LOW_MEMORY */ -#define FASL_Offset_First_Free 15 /* Used to clear header */ +#define FASL_Offset_First_Free 16 /* Used to clear header */ /* Aliases for backwards compatibility. */ diff --git a/v7/src/microcode/load.c b/v7/src/microcode/load.c index cf4403dae..8e771ed44 100644 --- a/v7/src/microcode/load.c +++ b/v7/src/microcode/load.c @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: load.c,v 9.34 1993/11/04 19:33:21 gjr Exp $ +$Id: load.c,v 9.35 1993/11/08 06:34:30 gjr Exp $ Copyright (c) 1987-1993 Massachusetts Institute of Technology @@ -75,7 +75,8 @@ static long Dumped_Heap_Top, Dumped_Constant_Top, Primitive_Table_Size, Primitive_Table_Length, C_Code_Table_Size, C_Code_Table_Length, - dumped_processor_type, dumped_interface_version; + dumped_processor_type, dumped_interface_version, + dumped_memory_base; static unsigned long dumped_checksum, computed_checksum; @@ -186,6 +187,7 @@ DEFUN (initialize_variables_from_fasl_header, (buffer), C_Code_Table_Length = (OBJECT_DATUM (buffer[FASL_Offset_C_Length])); C_Code_Table_Size = (OBJECT_DATUM (buffer[FASL_Offset_C_Size])); } + dumped_memory_base = ((long) buffer[FASL_Offset_Mem_Base]); #ifndef INHIBIT_FASL_VERSION_CHECK /* The error messages here should be handled by the runtime system! */ diff --git a/v8/src/microcode/fasl.h b/v8/src/microcode/fasl.h index aa53ae9d4..259404053 100644 --- a/v8/src/microcode/fasl.h +++ b/v8/src/microcode/fasl.h @@ -1,6 +1,6 @@ /* -*-C-*- -$Id: fasl.h,v 9.34 1993/11/04 04:02:49 gjr Exp $ +$Id: fasl.h,v 9.35 1993/11/08 06:34:23 gjr Exp $ Copyright (c) 1987-1993 Massachusetts Institute of Technology @@ -60,8 +60,9 @@ MIT in each case. */ #define FASL_Offset_Check_Sum 12 /* Header and data checksum. */ #define FASL_Offset_C_Length 13 /* Number of entries in the C code table */ #define FASL_Offset_C_Size 14 /* Size of C code table in SCHEME_OBJECTs */ +#define FASL_Offset_Mem_Base 15 /* Base address when not HEAP_IN_LOW_MEMORY */ -#define FASL_Offset_First_Free 15 /* Used to clear header */ +#define FASL_Offset_First_Free 16 /* Used to clear header */ /* Aliases for backwards compatibility. */ -- 2.25.1