[bknr-cvs] r2335 - branches/bos/projects/bos/m2

ksprotte at common-lisp.net ksprotte at common-lisp.net
Thu Jan 17 16:30:36 UTC 2008


Author: ksprotte
Date: Thu Jan 17 11:30:34 2008
New Revision: 2335

Modified:
   branches/bos/projects/bos/m2/allocation-cache.lisp
   branches/bos/projects/bos/m2/allocation.lisp
   branches/bos/projects/bos/m2/packages.lisp
Log:
stripped allocation-cache- prefix from some functions

Modified: branches/bos/projects/bos/m2/allocation-cache.lisp
==============================================================================
--- branches/bos/projects/bos/m2/allocation-cache.lisp	(original)
+++ branches/bos/projects/bos/m2/allocation-cache.lisp	Thu Jan 17 11:30:34 2008
@@ -135,7 +135,7 @@
   "Are regions of size N indexed?"
   (<= 1 n +threshold+))
 
-(defun allocation-cache-find-exact-match (n &key remove)
+(defun find-exact-match (n &key remove)
   "Will return a free contigous region of size N
 as a list of m2 instances. If no such region exactly
 matching N can be found, simply returns NIL.
@@ -147,7 +147,7 @@
     (remove (index-pop n))
     (t (index-lookup n))))
 
-(defun allocation-cache-add-area (allocation-area)
+(defun add-area (allocation-area)
   (dolist (region (free-regions allocation-area)
 	   allocation-area)
     (let ((size (length region)))
@@ -155,12 +155,12 @@
 	  (index-push size region)
 	  (incf (ignored-size *allocation-cache*) size)))))
 
-(defun allocation-cache-free-regions-count ()
+(defun free-regions-count ()
   (iter
     (for regions in-vector (allocation-cache-index *allocation-cache*))
     (summing (length regions))))
 
-(defun allocation-cache-free-regions-pprint ()
+(defun free-regions-pprint ()
   (iter
     (for regions in-vector (allocation-cache-index *allocation-cache*))
     (for size upfrom 1)
@@ -173,7 +173,7 @@
   (setq *allocation-cache* (make-allocation-cache))
   (dolist (allocation-area (class-instances 'allocation-area))
     (when (allocation-area-active-p allocation-area)
-      (allocation-cache-add-area allocation-area))))
+      (add-area allocation-area))))
 
 (defun suggest-free-region-size ()
   (iter

Modified: branches/bos/projects/bos/m2/allocation.lisp
==============================================================================
--- branches/bos/projects/bos/m2/allocation.lisp	(original)
+++ branches/bos/projects/bos/m2/allocation.lisp	Thu Jan 17 11:30:34 2008
@@ -625,7 +625,7 @@
   (assert (plusp n))
   (unless (in-transaction-p)
     (error "find-free-m2s called outside of the allocation transaction"))
-  (or (bos.m2.allocation-cache:allocation-cache-find-exact-match n :remove t) 
+  (or (bos.m2.allocation-cache:find-exact-match n :remove t) 
       (some (lambda (area) (allocation-area-find-free-m2s area n))
 	    (active-allocation-areas))
       (let ((area (find-inactive-allocation-area)))

Modified: branches/bos/projects/bos/m2/packages.lisp
==============================================================================
--- branches/bos/projects/bos/m2/packages.lisp	(original)
+++ branches/bos/projects/bos/m2/packages.lisp	Thu Jan 17 11:30:34 2008
@@ -211,6 +211,9 @@
   (:shadowing-import-from :cl-interpol #:quote-meta-chars)
   (:export #:cert-daemon))
 
+;;; maybe there is a nicer way to do this
+;;; if you want to test this run ./build.sh at least twice !
+(intern "POINT-IN-POLYGON-P" :bos.m2) 
 
 (defpackage :bos.m2.allocation-cache
   (:use :cl		



More information about the Bknr-cvs mailing list