E&S CVS Commit: PyProtocols - Index optimization: share seed lists for equivalent criteria so that less

pje at eby-sarna.com pje at eby-sarna.com
Thu Apr 21 11:22:01 EDT 2005


Module Name:	PyProtocols
Committed By:	pje
Date:		Thu Apr 21 15:31:34 UTC 2005

Modified Files:
	PyProtocols/src/dispatch: interfaces.py predicates.py strategy.py

Log Message:
Index optimization: share seed lists for equivalent criteria so that less
memory is used and index operations run faster when there is more than one
case using the same criterion.  For those indexing operations that are
O(n^2), the "n" is now the number of distinct criteria instead of the
number of cases, so the growth of "n" should be less than the growth of the
generic function overall.  In order to support this optimization,
ICriterion objects must now be hashable, and return equal hashes for equal
criteria.  So, AbstractCriterion now provides some basic support for
automatic hashing and comparison if you invoke AbstractCriterion.__init__(
self,data) where 'data' is the value to be used for hashing and comparison.


To view diffs of this commit, you can use the following URL(s):
http://cvs.eby-sarna.com/PyProtocols/src/dispatch/interfaces.py.diff?r1=1.17&r2=1.18
http://cvs.eby-sarna.com/PyProtocols/src/dispatch/predicates.py.diff?r1=1.20&r2=1.21
http://cvs.eby-sarna.com/PyProtocols/src/dispatch/strategy.py.diff?r1=1.36&r2=1.37

To generate a diff of this commit:
cvs rdiff -r1.17 -r1.18 PyProtocols/src/dispatch/interfaces.py
cvs rdiff -r1.20 -r1.21 PyProtocols/src/dispatch/predicates.py
cvs rdiff -r1.36 -r1.37 PyProtocols/src/dispatch/strategy.py

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




More information about the source-changes mailing list