diff --git a/contrib/sb-posix/constants.lisp b/contrib/sb-posix/constants.lisp index 6e055053c..63a04a53e 100644 --- a/contrib/sb-posix/constants.lisp +++ b/contrib/sb-posix/constants.lisp @@ -579,7 +579,7 @@ (:integer log-warning "LOG_WARNING" "Log severity level denoting a warning." t) #-win32 - (:integer + (:integer log-notice "LOG_NOTICE" "Log severity level denoting non-errors that may require special handling." t) #-win32 (:integer @@ -587,5 +587,5 @@ #-win32 (:integer log-debug "LOG_DEBUG" "Log severity level denoting debugging information ." t) - + ) diff --git a/src/compiler/fopcompile.lisp b/src/compiler/fopcompile.lisp index 23c534daa..31e87f60f 100644 --- a/src/compiler/fopcompile.lisp +++ b/src/compiler/fopcompile.lisp @@ -384,17 +384,11 @@ (cond ;; Lambda forms are compiled with the real compiler ((lambda-form-p form) - ;; We wrap the real lambda inside another one to ensure - ;; that the compiler doesn't e.g. let convert it, thinking - ;; that there are no external references. - (let* ((handle (%compile `(lambda () ,form) + (let* ((handle (%compile form *compile-object* :path path))) (when for-value-p - (sb!fasl::dump-push handle *compile-object*) - ;; And then call the wrapper function when loading the FASL - (sb!fasl::dump-fop 'sb!fasl::fop-funcall *compile-object*) - (sb!fasl::dump-byte 0 *compile-object*)))) + (sb!fasl::dump-push handle *compile-object*)))) ;; While function names are translated to a call to FDEFINITION. ((legal-fun-name-p form) (dump-fdefinition form)) diff --git a/src/compiler/locall.lisp b/src/compiler/locall.lisp index f480fcfa6..e2af18ddd 100644 --- a/src/compiler/locall.lisp +++ b/src/compiler/locall.lisp @@ -1050,7 +1050,8 @@ ;;; true if we converted. (defun maybe-let-convert (clambda) (declare (type clambda clambda)) - (unless (declarations-suppress-let-conversion-p clambda) + (unless (or (declarations-suppress-let-conversion-p clambda) + (functional-has-external-references-p clambda)) ;; We only convert to a LET when the function is a normal local ;; function, has no XEP, and is referenced in exactly one local ;; call. Conversion is also inhibited if the only reference is in @@ -1166,7 +1167,8 @@ (defun maybe-convert-to-assignment (clambda) (declare (type clambda clambda)) (when (and (not (functional-kind clambda)) - (not (functional-entry-fun clambda))) + (not (functional-entry-fun clambda)) + (not (functional-has-external-references-p clambda))) (let ((outside-non-tail-call nil) (outside-call nil)) (when (and (dolist (ref (leaf-refs clambda) t) diff --git a/src/compiler/main.lisp b/src/compiler/main.lisp index 74cba285f..d13e07da9 100644 --- a/src/compiler/main.lisp +++ b/src/compiler/main.lisp @@ -986,6 +986,7 @@ (assert-global-function-definition-type name locall-fun)) (setf (functional-entry-fun fun) locall-fun (functional-kind fun) :external + (functional-has-external-references-p locall-fun) t (functional-has-external-references-p fun) t) fun))) diff --git a/tests/compiler.pure.lisp b/tests/compiler.pure.lisp index 95d2928b4..7db4d3ae7 100644 --- a/tests/compiler.pure.lisp +++ b/tests/compiler.pure.lisp @@ -1375,8 +1375,12 @@ (handler-case (compile nil '(lambda (x) (declare (optimize (speed 3) (safety 0))) (the double-float (sqrt (the double-float x))))) - (sb-ext:compiler-note () - (error "Compiler does not trust result type assertion."))) + (sb-ext:compiler-note (c) + ;; Ignore the note for the float -> pointer conversion of the + ;; return value. + (unless (string= (car (last (sb-c::simple-condition-format-arguments c))) + "") + (error "Compiler does not trust result type assertion.")))) (let ((f (compile nil '(lambda (x) (declare (optimize speed (safety 0))) @@ -1901,14 +1905,15 @@ (compile nil '(lambda (x) (declare (optimize (speed 3))) (1+ x)))) - ;; forced-to-do GENERIC-+, etc - (assert (> count0 0)) + ;; forced-to-do GENERIC-+, etc, possible word -> bignum conversion note + (assert (> count0 1)) (handler-bind ((sb-ext:compiler-note (lambda (c) (incf count1)))) (compile nil '(lambda (x) (declare (optimize (speed 3))) (check-type x fixnum) (1+ x)))) - (assert (= count1 0))) + ;; Only the posssible word -> bignum conversion note + (assert (= count1 1))) ;;; Up to 0.9.8.22 x86-64 had broken return value handling in the ;;; %SET-SAP-REF-DOUBLE/SINGLE VOPs. diff --git a/tests/debug.impure.lisp b/tests/debug.impure.lisp index 25ad2a72b..b64e17227 100644 --- a/tests/debug.impure.lisp +++ b/tests/debug.impure.lisp @@ -123,9 +123,7 @@ ;; extra foreign frames below regular frames. (let ((end (last backtrace #-win32 2 #+win32 4))) (unless (equal (caar end) - (if *show-entry-point-details* - '(sb-c::tl-xep sb-impl::toplevel-init) - 'sb-impl::toplevel-init)) + 'sb-impl::toplevel-init) (print (list :backtrace-stunted (caar end))) (setf result nil))) (return-from outer-handler))))) diff --git a/version.lisp-expr b/version.lisp-expr index b6c2a62d1..1a0b2153a 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".) -"1.0.1.30" +"1.0.1.31"