From: Alexey Dejneka Date: Fri, 14 Nov 2003 12:44:42 +0000 (+0000) Subject: 0.8.5.37: X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=70ea2f8c140246a8b5f7cb126198ff068630258f;p=sbcl.git 0.8.5.37: * Fix PFD bug MISC.165: unify treating of TAIL-CALLS in LET-convertion. --- diff --git a/src/compiler/locall.lisp b/src/compiler/locall.lisp index 7edff10..f370eb3 100644 --- a/src/compiler/locall.lisp +++ b/src/compiler/locall.lisp @@ -953,11 +953,13 @@ ;;; new references to it. (defun let-convert (fun call) (declare (type clambda fun) (type basic-combination call)) - (let ((next-block (if (node-tail-p call) - nil - (insert-let-body fun call)))) + (let* ((next-block (insert-let-body fun call)) + (next-block (if (node-tail-p call) + nil + next-block))) (move-return-stuff fun call next-block) - (merge-lets fun call))) + (merge-lets fun call) + (setf (node-tail-p call) nil))) ;;; Reoptimize all of CALL's args and its result. (defun reoptimize-call (call) diff --git a/tests/compiler.pure.lisp b/tests/compiler.pure.lisp index 13aad3e..37698fa 100644 --- a/tests/compiler.pure.lisp +++ b/tests/compiler.pure.lisp @@ -846,3 +846,25 @@ a))) 0) -20343)) + +;;; MISC.165 +(assert (eql (funcall + (compile + nil + '(lambda (a b c) + (block b3 + (flet ((%f15 + (f15-1 f15-2 f15-3 + &optional + (f15-4 + (flet ((%f17 + (f17-1 f17-2 f17-3 + &optional (f17-4 185155520) (f17-5 c) + (f17-6 37)) + c)) + (%f17 -1046 a 1115306 (%f17 b -146330 422) -337817))) + (f15-5 a) (f15-6 -40)) + (return-from b3 -16))) + (multiple-value-call #'%f15 (values -519354 a 121 c -1905)))))) + 0 0 -5) + -16)) diff --git a/version.lisp-expr b/version.lisp-expr index 9f7237b..f4b1d15 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"0.8.5.36" +"0.8.5.37"