From 9215829e58457fd9cab3a3cd53bba7a063909e1b Mon Sep 17 00:00:00 2001 From: Douglas Katzman Date: Mon, 7 Jul 2014 21:07:59 -0400 Subject: [PATCH] "Downgrade" FIXME comment. It's not broken, just complicated. --- src/code/target-package.lisp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/code/target-package.lisp b/src/code/target-package.lisp index 5217b6f17..2df0f43f1 100644 --- a/src/code/target-package.lisp +++ b/src/code/target-package.lisp @@ -949,9 +949,16 @@ implementation it is ~S." *default-package-use-list*) ;; but accept a LENGTH. Given a non-simple string, ;; we need copy it only if the cumulative displacement ;; into the underlying simple-string is nonzero. - ;; FIXME: something in here generates a type-check for - ;; simple-rank-1-array, which ought to have been obviated - ;; by the assertion in the XEP that NAME is a STRING. + ;; There are two things that can be improved + ;; about the generated code here: + ;; 1. if X is known to satisfy STRINGP (generally any rank-1 array), + ;; then testing SIMPLE--STRING-P should not + ;; re-test the lowtag. This is constrained by the backends, + ;; because there are no type vops that assume a known lowtag. + ;; 2. if X is known to satisfy VECTORP, then + ;; (NOT (ARRAY-HEADER-P)) implies SIMPLE-P, but the compiler + ;; does not actually know that, and generates a check. + ;; This is more of a front-end issue. `(multiple-value-bind (name length) (if (simple-string-p name) (values name (length name)) -- 2.11.4.GIT