[m-dev.] diff: remove --heap-space

Zoltan Somogyi zs at cs.mu.OZ.AU
Mon Apr 26 17:29:00 AEST 1999


Remove the obsolete option --heap-space, which was used only with NU-Prolog.

compiler/options.m:
	Remove the option.

compiler/handle_options.m:
	Don't set the option.

doc/user_guide.texi:
	Don't document the option.

library/io.m:
	Delete the code that is only invoked when the option is set.

Zoltan.

cvs diff: Diffing compiler
Index: compiler/handle_options.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/handle_options.m,v
retrieving revision 1.73
diff -u -b -u -r1.73 handle_options.m
--- handle_options.m	1999/04/23 01:02:39	1.73
+++ handle_options.m	1999/04/26 07:25:08
@@ -209,13 +209,6 @@
 
 postprocess_options_2(OptionTable, GC_Method, TagsMethod, ArgsMethod,
 		PrologDialect, TermNorm, TraceLevel, Error) -->
-	% work around for NU-Prolog problems
-	( { map__search(OptionTable, heap_space, int(HeapSpace)) } ->
-		io__preallocate_heap_space(HeapSpace)
-	;
-		[]
-	),
-
 	{ unsafe_promise_unique(OptionTable, OptionTable1) }, % XXX
 	globals__io_init(OptionTable1, GC_Method, TagsMethod, ArgsMethod,
 		PrologDialect, TermNorm, TraceLevel),
Index: compiler/options.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/options.m,v
retrieving revision 1.260
diff -u -b -u -r1.260 options.m
--- options.m	1999/04/23 01:02:55	1.260
+++ options.m	1999/04/26 07:24:08
@@ -304,7 +304,6 @@
 		;	link_libraries
 		;	link_objects
 	% Miscellaneous Options
-		;	heap_space
 		;	search_directories
 		;	intermod_directories
 		;	use_search_directories_for_intermod
@@ -648,7 +647,6 @@
 ]).
 option_defaults_2(miscellaneous_option, [
 		% Miscellaneous Options
-	heap_space		-	int(0),
 	filenames_from_stdin	-	bool(no),
 	search_directories 	-	accumulating(["."]),
 	intermod_directories	-	accumulating([]),
@@ -1016,7 +1014,6 @@
 
 % misc options
 long_option("help",			help).
-long_option("heap-space",		heap_space).
 long_option("search-directory",		search_directories).
 long_option("intermod-directory",	intermod_directories).
 long_option("use-search-directories-for-intermod",
@@ -2166,13 +2163,6 @@
 options_help_misc -->
 	io__write_string("\nMiscellaneous Options:\n"),
 	write_tabbed_lines([
-	% 	"\t-H <n>, --heap-space <n>",
-	% 	"\t\tPre-allocate <n> kilobytes of heap space.",
-	% 	"\t\tThis option is now obsolete.  In the past it",
-	% 	"\t\twas used to avoid NU-Prolog's",
-	% 	"\t\t\t""Panic: growing stacks has required shifting the heap""",
-	% 	"\t\tmessage.",
-
 		"-I <dir>, --search-directory <dir>",
 		"\tAdd <dir> to the list of directories to be searched for \n\t\timported modules.",
 		"--intermod-directory <dir>",
cvs diff: Diffing compiler/notes
cvs diff: Diffing doc
Index: doc/user_guide.texi
===================================================================
RCS file: /home/mercury1/repository/mercury/doc/user_guide.texi,v
retrieving revision 1.170
diff -u -b -u -r1.170 user_guide.texi
--- user_guide.texi	1999/04/23 01:03:24	1.170
+++ user_guide.texi	1999/04/26 07:24:45
@@ -3635,13 +3635,6 @@
 @itemx --help
 Print a usage message.
 
- at c @item -H @var{n}
- at c @itemx --heap-space @var{n}
- at c Pre-allocate @var{n} kilobytes of heap space.
- at c This option is now obsolete.  In the past it was used to avoid
- at c NU-Prolog's "Panic: growing stacks has required shifting the heap"
- at c message.
-
 @sp 1
 @item --filenames-from-stdin
 Read then compile a newline terminated module name or file name from the
cvs diff: Diffing library
Index: library/io.m
===================================================================
RCS file: /home/mercury1/repository/mercury/library/io.m,v
retrieving revision 1.174
diff -u -b -u -r1.174 io.m
--- io.m	1999/03/10 23:24:33	1.174
+++ io.m	1999/04/26 07:26:32
@@ -960,11 +960,6 @@
 :- pred io__report_full_memory_stats(io__state, io__state).
 :- mode io__report_full_memory_stats(di, uo) is det.
 
-	% Preallocate heap space (to avoid NU-Prolog panic).
-
-:- pred io__preallocate_heap_space(int, io__state, io__state).
-:- mode io__preallocate_heap_space(in, di, uo) is det.
-
 /*** no longer supported, sorry
 :- pred io__gc_call(pred(io__state, io__state), io__state, io__state).
 :- mode io__gc_call(pred(di, uo) is det, di, uo) is det.
@@ -3165,14 +3160,6 @@
 :- pragma c_code(io__set_exit_status(ExitStatus::in, IO0::di, IO::uo),
 		will_not_call_mercury, "
 	mercury_exit_status = ExitStatus;
-	update_io(IO0, IO);
-").
-
-:- pragma c_code(io__preallocate_heap_space(HeapSpace::in, IO0::di, IO::uo),
-		[will_not_call_mercury, thread_safe], "
-	/* HeapSpace not used */
-	/* don't do anything - preallocate_heap_space was just a
-	   hack for NU-Prolog */
 	update_io(IO0, IO);
 ").
 
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list