RTL: Compile prompts
authorAndy Wingo <wingo@igalia.com>
Mon, 14 Oct 2013 14:13:57 +0000 (16:13 +0200)
committerAndy Wingo <wingo@igalia.com>
Mon, 14 Oct 2013 14:13:57 +0000 (16:13 +0200)
commit8d59d55e866666a4ed3b9695638265be62b20af0
tree3e1cbb7f192f89096cc9ca0414c946bf65baef95
parent82f4bac420db15b3d41313f1f0213ea34a443d60
RTL: Compile prompts

* libguile/vm-engine.c (prompt): Adapt to explicitly set the saved SP so
  we know how many incoming values the handler will receive, and to make
  escape-only? a flag.

* module/language/cps/compile-rtl.scm (emit-rtl-sequence): $prompt
  should only be found in a "seq" context, as it just pushes on a prompt
  and doesn't bind any values.  On the other hand it should emit
  appropriate code for the handler to bind its values, so do that.

* module/language/cps/slot-allocation.scm ($cont-allocation): Add a note
  that proc-slot is used by prompts as well.
  (allocate-slots): Compute the allocation of a prompt handler's args.

* module/language/tree-il/compile-cps.scm (convert): Use "unwind"
  instead of the nonexistent "pop-prompt".

* module/system/vm/disassembler.scm (code-annotation): Adapt to change
  in prompt VM op.
libguile/vm-engine.c
module/language/cps/compile-rtl.scm
module/language/cps/slot-allocation.scm
module/language/tree-il/compile-cps.scm
module/system/vm/disassembler.scm