Skip to content
Snippets Groups Projects
Commit f3fe0b8d authored by gerd's avatar gerd
Browse files

Dynamic-extent support for x86. Use boot16.lisp for

	bootstrapping.

	* src/bootfiles/18e/boot16.lisp: New file.

	* src/docs/cmu-user/extensions.tex (Dynamic-Extent Declarations):
	New section.

	* src/compiler/x86/macros.lisp (dynamic-extent-allocation):
	Rename from stack-allocation, save an instruction.
	(allocation): Don't call trust-dynamic-extent-declaration-p.

	* src/compiler/x86/alloc.lisp (%dynamic-extent-start)
	(%dynamic-extent-end): New vops.
	(list-or-list*): Add constant arg dynamic-extent.
	(fixed-alloc): Likewise.

	* src/compiler/generic/vm-ir2tran.lisp (do-fixed-alloc): Call
	fixed-alloc with dynamic-extent arg.

	* src/compiler/hppa/alloc.lisp (%dynamic-extent-start)
	(%dynamic-extent-end): Add dummy vops.
	* src/compiler/mips/alloc.lisp:
	* src/compiler/ppc/alloc.lisp:
	* src/compiler/alpha/alloc.lisp:
	* src/compiler/rt/alloc.lisp: Likewise.

	* src/compiler/seqtran.lisp (mapper-transform): Add dynamic-extent
	declarations.

	* src/compiler/node.lisp (continuation): Add slot
	dynamic-extent.
	(cleanup): Add :dynamic-extent to type of slot kind.

	* src/compiler/knownfun.lisp (dynamic-extent-closure-safe):
	New attribute.

	* src/compiler/ir2tran.lisp (ir2-stack-allocate): New function.
	(ir2-convert-closure): Handle dynamic-extent case differently.
	(%dynamic-extent, %dynamic-extent-start, %dynamic-extent-end)
	<ir2-convert>: New optimizers.
	(list, list*): Handle dynamic-extent.

	* src/compiler/ir1tran.lisp (*trust-dynamic-extent-declarations*)
	(*dynamic-extent-trace*): New variables.
	(trust-dynamic-extent-declaration-p): New function.
	(process-dynamic-extent-declaration)
	(dynamic-extent-allocation-p, dynamic-extent-closure-args)
	(gen-%dynamic-extent, with-dynamic-extent): New functions/macros.
	(ir1-convert-combination): Handle dynamic-extent closure args.
	(ir1-convert-combination-args): Add arg dynamic-extent-args.
	Set continuation-dynamic-extent for these args.
	(process-dynamic-extent-declaration): Rewritten.
	(ir1-convert-dynamic-extent-bindings): New function.
	(ir1-convert-special-bindings): Call it.
	(ir1-convert-lambda-body): Handle dynamic-extent rest lists.
	(let): Handle dynamic-extent vars.
	(let*): Call ir1-convert-dynamic-extent-bindings.

	* src/compiler/globaldb.lisp (*trust-dynamic-extent-declarations*)
	(trust-dynamic-extent-declaration-p): Remove.

	* src/compiler/fndb.lisp: Add dynamic-extent-closure-safe
	attribute to assorted functions.

	* src/compiler/envanal.lisp (environment-analyze): Call
	find-dynamic-extent-safe-closures.
	(emit-cleanups): Handle :dynamic-extent cleanups.
	(*suppress-dynamic-extent-closure-safe*): New variable.
	(mark-dynamic-extent-safe-closures)
	(find-dynamic-extent-safe-closures): New functions.

	* src/compiler/byte-comp.lisp (compute-produces-and-consumes):
	Treat :dynamic-extent like :tagbody cleanups.

	* src/code/exports.lisp ("C"): Export ir2-stack-allocate,
	%dynamic-extent, %dynamic-extent-start, %dynamic-extent-end.

	* src/code/byte-interp.lisp (%dynamic-extent):
	(%dynamic-extent-start, %dynamic-extent-end): New functions.
	(toplevel): Enable block compilation.
parent 2f40ed5a
No related branches found
No related tags found
No related merge requests found
Showing
with 707 additions and 253 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment