From cba6e396b6b92bdc8f830ce482962d0c7d63dfb0 Mon Sep 17 00:00:00 2001 From: mainzelm Date: Thu, 8 Nov 2001 08:22:15 +0000 Subject: [PATCH] Removed definitions that also exist in main.c Increased initial heap size --- c/init.c | 34 +++++++--------------------------- 1 file changed, 7 insertions(+), 27 deletions(-) diff --git a/c/init.c b/c/init.c index b5f8a3e..8a4f185 100644 --- a/c/init.c +++ b/c/init.c @@ -7,30 +7,6 @@ #include "scheme48vm.h" #include "scheme48heap.h" -/* I bumped this up from 1.5 Mcell because the debugging info put us over -** the top. -Olin -*/ -#if !defined(DEFAULT_HEAP_SIZE) -/* 4 megacell = 16 megabytes (8 meg per semispace) */ -#define DEFAULT_HEAP_SIZE 4000000L -#endif - -#if !defined(DEFAULT_STACK_SIZE) -/* 2500 cells = 10000 bytes */ -#define DEFAULT_STACK_SIZE 2500L -#endif - -#if defined(STATIC_AREAS) -#define DEFAULT_IMAGE_NAME NULL -#else - -/* DEFAULT_IMAGE_NAME should be defined using the -D switch to cc. */ -#if !defined(DEFAULT_IMAGE_NAME) -#define DEFAULT_IMAGE_NAME "scheme48.image" -#endif - -#endif /* STATIC_AREAS */ - extern void s48_sysdep_init(void); extern void s48_initialize_external_modules(void); @@ -41,11 +17,16 @@ char *s48_reloc_file; /* dynamic loading will set this */ char *prog_name; +void *heap, *stack; + int s48_main (long heap_size, long stack_size, char *image_name, int argc, char** argv) { - return internal_s48_main(heap_size, stack_size, "libscsh", "libscsh", - image_name, argc, argv); + int ret = internal_s48_main(heap_size, stack_size, "libscsh", "libscsh", + image_name, argc, argv); + free(heap); + free(stack); + return ret; } int @@ -53,7 +34,6 @@ internal_s48_main(long heap_size, long stack_size, char * _prog_name, char* object_file, char *image_name, int argc, char** argv) { long return_value; - void *heap, *stack; long required_heap_size; int warn_undefined_imported_bindings_p = 1;