wingo pushed a commit to branch wip-2.1.2
in repository guile.
commit 34f3fb78e09dd3220cfc615ffc0850d1bf344438
Author: Andy Wingo <[email protected]>
Date: Wed Oct 28 10:14:30 2015 +0000
Fix slot-allocation to make 'return' not need to alloc-frame
* module/language/cps/slot-allocation.scm (compute-frame-sizes): Ensure
that frames with `return' have space to shuffle the arg into return
position.
---
module/language/cps/slot-allocation.scm | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/module/language/cps/slot-allocation.scm
b/module/language/cps/slot-allocation.scm
index b306898..423da2c 100644
--- a/module/language/cps/slot-allocation.scm
+++ b/module/language/cps/slot-allocation.scm
@@ -660,6 +660,9 @@ are comparable with eqv?. A tmp slot may be used."
(call-size label (1+ (length args)) size))
(($ $values args)
(shuffle-size (get-shuffles label) size))
+ (($ $primcall 'return (arg))
+ ;; Return will shuffle arg into fp-relative slot 1.
+ (max size 2))
(_ size)))))
(($ $kreceive)
(values frame-sizes clause