1.0.0.10:
authorJuho Snellman <jsnell@iki.fi>
Fri, 1 Dec 2006 18:13:44 +0000 (18:13 +0000)
committerJuho Snellman <jsnell@iki.fi>
Fri, 1 Dec 2006 18:13:44 +0000 (18:13 +0000)
Set SB-PCL::*MAX-EMF-PRECOMPUTATION-METHODS* to a non-NIL value, to
        fix performance problems when loading generic functions with
        hundreds of methods. (Reported by Todd Sabin and Jeremy Brown)

        * Use a small value, rather than 100 as used in CMUCL, to flush
          out possible problems with doing a limited amount of precomputation.

NEWS
src/pcl/dfun.lisp
version.lisp-expr

diff --git a/NEWS b/NEWS
index cd951c7..0b77999 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -11,6 +11,9 @@ changes in sbcl-1.0.1 relative to sbcl-1.0:
     CALL-NEXT-METHOD (reported by Pascal Costanza)
   * bug fix: an error was signaled at startup if the HOME environment 
     variable was defined, but had an empty value (reported by Peter Van Eynde)
+  * optimization: loading generic functions no longer takes O(n^2) time,
+    proportional to the amount of methods in the generic function
+    (reported by Todd Sabin and Jeremy Brown)        
   * optimization: the FIND and POSITION family of sequence functions
     are significantly faster on arrays whose element types have been
     declared.
index a83e037..e9cd883 100644 (file)
@@ -756,8 +756,16 @@ Except see also BREAK-VICIOUS-METACIRCLE.  -- CSR, 2003-05-28
 (defvar *lazy-dfun-compute-p* t)
 (defvar *early-p* nil)
 
+;;; This variable is used for controlling the load-time effective
+;;; method precomputation: precomputation will only be done for emfs
+;;; with fewer than methods than this value. This value has
+;;; traditionally been NIL on SBCL (meaning that precomputation will
+;;; always be done) but that makes method loading O(n^2). Use a small
+;;; value for now, to flush out any possible problems that doing a
+;;; limited amount of precomputation might cause. If none appear, we
+;;; might change it to a larger value later. -- JES, 2006-12-01
 (declaim (type (or null unsigned-byte) *max-emf-precomputation-methods*))
-(defvar *max-emf-precomputation-methods* nil)
+(defvar *max-emf-precomputation-methods* 1)
 
 (defun finalize-specializers (gf)
   (let ((methods (generic-function-methods gf)))
index 394585d..9fd3c95 100644 (file)
@@ -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.0.9"
+"1.0.0.10"