From ab23de6dc194278456498a23c1b27075d7a52ae7 Mon Sep 17 00:00:00 2001 From: ram <ram> Date: Tue, 14 Apr 1992 18:09:01 +0000 Subject: [PATCH] Don't substitute out LET variables when the initial value is a reference to a :NOTINLINE functional. The inlinep information must be retained, since we count on :NOTLININE calls never being local call converted. --- compiler/ir1opt.lisp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/compiler/ir1opt.lisp b/compiler/ir1opt.lisp index a63ee046f..036cd7a79 100644 --- a/compiler/ir1opt.lisp +++ b/compiler/ir1opt.lisp @@ -7,7 +7,7 @@ ;;; Scott Fahlman or slisp-group@cs.cmu.edu. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ir1opt.lisp,v 1.43 1992/04/02 15:25:38 ram Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ir1opt.lisp,v 1.44 1992/04/14 18:09:01 ram Exp $") ;;; ;;; ********************************************************************** ;;; @@ -1104,14 +1104,18 @@ ;;; CONSTANT-REFERENCE-P -- Interface ;;; ;;; Return true if the value of Ref will always be the same (and is thus -;;; legal to substitute.) +;;; legal to substitute.) Even though the value of a FUNCTIONAL really can't +;;; change, we consider it non-constant when it is marker :NOTINLINE, since +;;; this is used as a flag to inhibit local call conversion, and must not be +;;; lost. ;;; (defun constant-reference-p (ref) (declare (type ref ref)) (let ((leaf (ref-leaf ref))) (typecase leaf (constant t) - (functional t) + (functional + (not (eq (ref-inlinep ref) :notinline))) (lambda-var (null (lambda-var-sets leaf))) (global-var -- GitLab