1.0.15.12: better scaling in the PCL cache
commit229d5b35ac98f606f24c90d8e5cc037cae3829cd
authorNikodemus Siivola <nikodemus@random-state.net>
Mon, 3 Mar 2008 19:34:18 +0000 (3 19:34 +0000)
committerNikodemus Siivola <nikodemus@random-state.net>
Mon, 3 Mar 2008 19:34:18 +0000 (3 19:34 +0000)
treec4211b9c2183ea489c6724056f3d1bac96759ec1
parent6e332c91239622ffa95acbb3d2d69b8995265aa9
1.0.15.12: better scaling in the PCL cache

 * When the cache reaches its maximum size, and entries need to be
   dropped, drop a random 50% of them, instead of the more
   deterministic set "ones that don't fit": this avoids getting stuck
   in a "add A dropping B, add B dropping A, ..." cycle which eats up
   ginormous amounts of time. Additionally, dropping 50% seems to be
   the best ratio -- experimentally, at least -- but it would be nice
   to have a proper analysis...

   Note: there is a point (possibly even before our current maximum
   cache size) where the allowed probe-depth grows so large that a
   tree would work better then a table. It would be good to gracefully
   replace the table based cache with a tree when it grows so large.
src/pcl/cache.lisp
version.lisp-expr