- 09 Jun, 2002 3 commits
-
-
Tim Peters authored
-
Tim Peters authored
-
Tim Peters authored
+ Documented the arguments. + Used BUCKET_SEARCH. + Vastly reduced nesting. + Changed the "*changed" argument to get set true whenever PER_CHANGED is called, i.e. whenever the bucket mutates. The purpose of *changed wasn't documented, and its only use was in the BTree set routine, which is known to have at least one bug. So it wasn't clear what the purpose of *changed was. What it did do is get set true if and only if the key was found in the bucket and its value was replaced, and I couldn't imagine a plausible reason for why the BTree set routine could care about that alone (all other calls to _bucket_set pass NULL, so there were no other clues). + Fixed all places where error returns didn't finish the persistence dance.
-
- 08 Jun, 2002 6 commits
-
-
Tim Peters authored
micro-optimized BUCKET_SEARCH macro. Change _bucket_get() to use it (more later).
-
Tim Peters authored
way out of date (prints stuff and asserts instead of raising unittest failures).
-
Tim Peters authored
does.
-
Tim Peters authored
-
Tim Peters authored
iteration protocol a destructor (finiSetIteration()), to plug assorted leaks of keys, values and even BTree nodes.
-
Tim Peters authored
-
- 07 Jun, 2002 2 commits
-
-
Jim Fulton authored
modifications were needed in Zope (only two files). A lot of unused (or rarely) features were removed from the Interface package. Slightly deeper imports are needed.
-
Tim Peters authored
initSetIteration(), because it specifically doesn't want to bother getting values out of mappings.
-
- 06 Jun, 2002 2 commits
-
-
Tim Peters authored
-
Jeremy Hylton authored
-
- 05 Jun, 2002 2 commits
-
-
Tim Peters authored
Elsewhere, repaired all other known cases where uses of the TEST_KEY_OR_SET macro did early exits without finishing persistence dances (Jeremy confirmed that's a Bad Thing -- creates unghostifiable cache hogs).
-
Tim Peters authored
a persistence dance on the buckets/sets it handles directly by itself. If so, a similar but different change is also needed on the Zope3 branch.
-
- 03 Jun, 2002 2 commits
-
-
Tim Peters authored
-
Tim Peters authored
SetIteration structs.
-
- 02 Jun, 2002 2 commits
-
-
Tim Peters authored
-
Tim Peters authored
Added lots of comments as a result. Redid parts of multiunion() because it was clearly leaking references tucked away inside its SetIteration struct. Added XXX comments in another place I'm pretty sure is leaking similar references in error cases (but am too tired to fix that now, if so).
-
- 01 Jun, 2002 2 commits
-
-
Tim Peters authored
-
Tim Peters authored
this now copies the keys into the work area in one gulp via memcpy, instead of iterating over them one at a time. Yields a nice speedup when it applies (and it usually should apply!).
-
- 31 May, 2002 15 commits
-
-
Tim Peters authored
from a sequence of ints in reverse-sorted order (a quadratic-time proposition). That doesn't test anything interesting in context, though. So fiddled it to do a larger input, but it runs much faster now.
-
Tim Peters authored
-
Tim Peters authored
-
Tim Peters authored
to squash delicate code duplication and for speed. + This is optimized in several subtle ways over the current method. This is documented in Maintainer.txt, along with a correctness proof. + I'll replace all the BTree searches with this soon. For now I just changed _BTree_get(). I *suspect* this also fixes a subtle bug introduced by the recent "don't ignore comparison error" patch: if a comparison did trigger an exception, the function just returned without doing the PER_ALLOW_DEACTIVATION + PER_ACCESSED dance. _BTree_get() does that dance again now.
-
Tim Peters authored
-
Tim Peters authored
-
Tim Peters authored
follows from that.
-
Tim Peters authored
neglected to change the name in new comments barely an hour old.
-
Tim Peters authored
"value" to "child". All the rest is mechanical name-changing. Next step is to change the decl of child from PyObject* to Sized*.
-
Tim Peters authored
the common initial fields (pyobject hair, persistence hair, 'size', and 'len'). I think Jim wants the data decls split into a separate file, but I'm unclear on why so am not doing that now. Renamed stuff for consistency. Added some comments. More BTree comments will end up in Maintainer.txt.
-
Tim Peters authored
+ Added interface docs. + Gave it a new "newsize" argument, for when the caller can gain speed by knowing in advance how many additional elements are needed. This isn't used yet, but will be by multiunion and planned "lopsided merge" optimizations (the intent is to grow the bucket big enough in one shot, then memcpy a large slice into the bucket). + When doubling the size, now sets a MemoryError exception on int overflow.
-
Tim Peters authored
vanished).
-
Toby Dickenson authored
long overdue merge of toby-cmp-error-branch. btrees no longer ignore exceptions raised by the key comparison function
-
Tim Peters authored
new MULTI_INT_UNION.
-
Tim Peters authored
-
- 30 May, 2002 4 commits
-
-
Jim Fulton authored
dumps. Copied source from 1.26.
-
Jim Fulton authored
initial fix causes core dumps. We'll reenable this test when the bug gets fixed (again).
-
Jeremy Hylton authored
Also: - call shuffle correctly. - simplify test_suite()
-
Tim Peters authored
input sets quickly, and will become much faster again soon (see TODO in C function multiunion_m).
-