From 094cc5356e622e1d6d80e14ed93eb94adc00328e Mon Sep 17 00:00:00 2001 From: Juho Snellman Date: Fri, 14 Apr 2006 05:53:09 +0000 Subject: [PATCH] 0.9.11.32: Treat TNs with no offset as deleted TNs when saving debug information. Fixes problem reported by NIIMI Satoshi (sbcl-devel "compilation error with optimization"). --- src/compiler/debug-dump.lisp | 4 ++-- tests/compiler.impure.lisp | 10 ++++++++++ version.lisp-expr | 2 +- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/src/compiler/debug-dump.lisp b/src/compiler/debug-dump.lisp index ff31524..797114a 100644 --- a/src/compiler/debug-dump.lisp +++ b/src/compiler/debug-dump.lisp @@ -331,7 +331,7 @@ (declare (type index flags)) (when minimal (setq flags (logior flags compiled-debug-var-minimal-p)) - (unless tn + (unless (and tn (tn-offset tn)) (setq flags (logior flags compiled-debug-var-deleted-p)))) (when (and (or (eq kind :environment) (and (eq kind :debug-environment) @@ -349,7 +349,7 @@ (vector-push-extend name buffer) (unless (zerop id) (vector-push-extend id buffer))) - (if tn + (if (and tn (tn-offset tn)) (vector-push-extend (tn-sc-offset tn) buffer) (aver minimal)) (when save-tn diff --git a/tests/compiler.impure.lisp b/tests/compiler.impure.lisp index 5fd8828..33af05f 100644 --- a/tests/compiler.impure.lisp +++ b/tests/compiler.impure.lisp @@ -1229,4 +1229,14 @@ (list (funcall #'target-fun 1 4) (funcall 'target-fun 1 4)))) (test-target-fun-called #'caller-fun-3 (list -3 5)) +;; Reported by NIIMI Satoshi +;; Subject: [Sbcl-devel] compilation error with optimization +;; Date: Sun, 09 Apr 2006 17:36:05 +0900 +(defun test-minimal-debug-info-for-unstored-but-used-parameter (n a) + (declare (optimize (speed 3) + (debug 1))) + (if (= n 0) + 0 + (test-minimal-debug-info-for-unstored-but-used-parameter (1- n) a))) + ;;; success diff --git a/version.lisp-expr b/version.lisp-expr index 158e71c..ed58ead 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.9.11.31" +"0.9.11.32" -- 1.7.10.4