Richard Brooksby
01f030d637
Removing unused fields from vmarenastruct.
...
Copied from Perforce
Change: 184567
ServerID: perforce.ravenbrook.com
2014-02-26 17:37:16 +00:00
Richard Brooksby
3c0b491102
Adding clarifying bracket.
...
Copied from Perforce
Change: 184566
ServerID: perforce.ravenbrook.com
2014-02-26 17:36:27 +00:00
Richard Brooksby
e991295b8d
Adding checking of the freecbs and zonecbss to arenacheck.
...
Copied from Perforce
Change: 184563
ServerID: perforce.ravenbrook.com
2014-02-26 14:25:01 +00:00
Richard Brooksby
cffd3e4834
Backing out zone set summary in the cbs. this isn't needed for speed now that there's a cbs per zone in the arena, and it will slow down all other cbss.
...
Copied from Perforce
Change: 184561
ServerID: perforce.ravenbrook.com
2014-02-26 14:24:34 +00:00
Richard Brooksby
01ee2406aa
Fixing bug where cbs overwrites its own blockpool pointer with garbage.
...
Copied from Perforce
Change: 184532
ServerID: perforce.ravenbrook.com
2014-02-25 19:19:37 +00:00
Richard Brooksby
67b596b72b
Implementing arenafreecbsdelete that might work on chunks that have interesting patterns of zone allocation.
...
Further tidying up.
Copied from Perforce
Change: 184531
ServerID: perforce.ravenbrook.com
2014-02-25 19:19:09 +00:00
Richard Brooksby
4295c4b9cc
Tidying up and wrapping arena cbs operations.
...
Copied from Perforce
Change: 184530
ServerID: perforce.ravenbrook.com
2014-02-25 16:58:23 +00:00
Richard Brooksby
51578a6bad
Removing the freering allocation cache, which breaks the cbs abstraction and does not give any benefit once we’re allocating from zonecbss.
...
Copied from Perforce
Change: 184529
ServerID: perforce.ravenbrook.com
2014-02-25 11:35:18 +00:00
Richard Brooksby
7f213d846c
Tidying up arena cbs mfs teardown.
...
Tidying up arena CBS initialisation and teardown.
Copied from Perforce
Change: 184523
ServerID: perforce.ravenbrook.com
2014-02-25 11:16:12 +00:00
Richard Brooksby
9d7ff6651d
Merging gcbench bug fix from master.
...
Copied from Perforce
Change: 184521
ServerID: perforce.ravenbrook.com
2014-02-25 11:15:52 +00:00
Richard Brooksby
c52f568137
Quick hack at allocating from per-zone cbs. promising performance.
...
Copied from Perforce
Change: 184507
ServerID: perforce.ravenbrook.com
2014-02-25 01:51:27 +00:00
Richard Brooksby
5fd80f897b
Merging bug fix for gcbench exit from development branch.
...
Copied from Perforce
Change: 184506
ServerID: perforce.ravenbrook.com
2014-02-25 01:49:49 +00:00
Richard Brooksby
6e46485dce
Catch-up merge from master, mainly to pick up gcbench fixes.
...
Copied from Perforce
Change: 184504
ServerID: perforce.ravenbrook.com
2014-02-25 01:29:12 +00:00
Richard Brooksby
20f1b7a26f
Bug fix. gcbench attempted to delete a nonexistent chain by default.
...
Copied from Perforce
Change: 184497
ServerID: perforce.ravenbrook.com
2014-02-24 23:03:10 +00:00
Richard Brooksby
392f089a2c
Bug fix. nonsensical case in cbsfindlargest when size is passed as zero.
...
Added RangeCopy.
Copied from Perforce
Change: 184496
ServerID: perforce.ravenbrook.com
2014-02-24 23:02:42 +00:00
Richard Brooksby
f16d920a66
Fixed a bug in cbsfindlargest where it always deleted the entire range found even when finddeletelow or finddeletehigh were passed.
...
Copied from Perforce
Change: 184493
ServerID: perforce.ravenbrook.com
2014-02-24 22:48:48 +00:00
Richard Brooksby
4b6c07ab25
Making assertions in cbsupdatenode critical, since this is extremely hot in any cbs with fast find.
...
Copied from Perforce
Change: 184492
ServerID: perforce.ravenbrook.com
2014-02-24 22:27:16 +00:00
Richard Brooksby
fa3858cfa6
Adding rangeisempty.
...
Copied from Perforce
Change: 184491
ServerID: perforce.ravenbrook.com
2014-02-24 22:26:22 +00:00
Richard Brooksby
e17d23dcea
Fixing compiler warning.
...
Copied from Perforce
Change: 184490
ServerID: perforce.ravenbrook.com
2014-02-24 22:25:48 +00:00
Gareth Rees
f01363221e
Refactor the computation of the chunk size into its own function, thus avoiding an "unreachable code" error from clang.
...
Copied from Perforce
Change: 184482
ServerID: perforce.ravenbrook.com
2014-02-24 21:32:22 +00:00
Richard Brooksby
8a9ab87a96
Initial hack at replacing the arena control pool with mvff.
...
Copied from Perforce
Change: 184489
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:41 +00:00
Richard Brooksby
5a5e95d6fa
Only finishing the cbs block pool when cbs created it. oops.
...
Copied from Perforce
Change: 184488
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:40 +00:00
Richard Brooksby
d0f823ec7c
Finishing the mvff block pool. oops.
...
Copied from Perforce
Change: 184487
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:40 +00:00
Richard Brooksby
236db01d08
Initialising a shared inline mfs for the cbss in mvff so that mvff can be used as the arena’s bootstrap and control pool.
...
Copied from Perforce
Change: 184486
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:40 +00:00
Richard Brooksby
858e77cabb
Bug fix. ensuring cbsfinddeleterange returns oldrangereturn even if it doesn’t delete a block.
...
Copied from Perforce
Change: 184485
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:39 +00:00
Richard Brooksby
dbf77fc811
Catch-up merge from master, mainly to pick up gcbench fix.
...
Copied from Perforce
Change: 184480
ServerID: perforce.ravenbrook.com
2014-02-24 21:14:13 +00:00
Gareth Rees
bc3e284dd7
Avoid use of unreachable code in protcatchthread on os x.
...
Copied from Perforce
Change: 184478
ServerID: perforce.ravenbrook.com
2014-02-24 18:07:14 +00:00
Richard Brooksby
0640804281
Reforming mvff pool class to avoid using segments and to actually have a chance to return memory to the arena.
...
Copied from Perforce
Change: 184467
ServerID: perforce.ravenbrook.com
2014-02-23 21:00:53 +00:00
Richard Brooksby
6f9f018101
Adding cbssize and freelistsize functions to calculate the size of freelist contents.
...
Copied from Perforce
Change: 184466
ServerID: perforce.ravenbrook.com
2014-02-23 20:59:44 +00:00
David Lovemore
4be8600326
Add pin-leaf option to gcbench.
...
Remove default chain from gcbench.
Copied from Perforce
Change: 184454
ServerID: perforce.ravenbrook.com
2014-02-23 13:44:54 +00:00
Richard Brooksby
2c0a968b2e
Making splaysplit and splayassemble general so that they can be used easily.
...
Copied from Perforce
Change: 184452
ServerID: perforce.ravenbrook.com
2014-02-23 12:18:18 +00:00
Richard Brooksby
b9a6a613a8
Returning the results of splitting in a structure so that it’s easier to pass them on to assemble.
...
Copied from Perforce
Change: 184451
ServerID: perforce.ravenbrook.com
2014-02-23 12:10:52 +00:00
Richard Brooksby
72dcf4aa74
Removing unnecessary case of splaying empty trees.
...
Copied from Perforce
Change: 184450
ServerID: perforce.ravenbrook.com
2014-02-23 11:52:21 +00:00
Richard Brooksby
a7451a424a
Adding a signature to splay tree structure. miscellaneous documentation and naming clean-up.
...
Copied from Perforce
Change: 184448
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
9a9369cb59
Pointer-reversing splay and assemble to avoid double traversal of side tree spines in the update case.
...
Copied from Perforce
Change: 184447
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
00b45122ee
Lifting zig and zag cases into common prefix to shorten splaysplit. a few percent faster.
...
Copied from Perforce
Change: 184446
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
9d3bbb41dd
Moving downward splay updates to after side tree linkage, allowing the optimiser to do a better job. produces about 10% speedup: xc/release/djbench -x 1234 --sshift 8 mvff
...
Copied from Perforce
Change: 184445
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
ee50a7703d
Implementing pointer-reversing tree traversal that does not disturb the tree shape, unlike the splay tree traversal, which flattens the tree into a list. replacing cbsiterate with this, knocking about 25% off the runtime of the test case: xc/release/djbench -x 1234 --sshift 8 mvff
...
Copied from Perforce
Change: 184444
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
a3e2e6bac3
Optimising splaytreeneighbours by observing that once one neighbour is found, the other neighbour is already in our hand in one of the side trees. this reduces the number of splays when coalescing.
...
Copied from Perforce
Change: 184443
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
26f8f1ddcd
Specialising left and right splay tree searches where no comparisons are necessary.
...
Copied from Perforce
Change: 184442
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
be51fa6829
Adding tree integrity check debugging function.
...
Copied from Perforce
Change: 184441
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
2a60898a04
Eliminating redundant passing of tree keys by adding a method to extract the key from a tree node.
...
Copied from Perforce
Change: 184440
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
d6d382cc34
Avoid dropping children of found node in non-update case. oops.
...
Copied from Perforce
Change: 184439
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
4c1c0009f8
Lifting out pointer-reversed updates.
...
Copied from Perforce
Change: 184438
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
959bc6b460
Generalising pointer reversal of tree spines.
...
Copied from Perforce
Change: 184437
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
4b18c932d8
Reducing excessive punctuation and removing unnecessary goto cases in splaysplay.
...
Copied from Perforce
Change: 184436
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
8fccc81c82
Avoiding general compare when searching for first and last nodes in a tree.
...
Copied from Perforce
Change: 184435
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
262de4e219
Fixing splaytreefind on empty tree. oops.
...
Regression test: xc/Debug/fbmtest 215526357
Copied from Perforce
Change: 184434
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
50146c866f
Splaysplay returns a compare to indicate the relationship of the new tree root to the key, eliminating some redundant tests, and making it more like treefind.
...
Allowing SplayTreeNext to deal with modification during iteration, so that iteration can be used to delete trees, for example.
Copied from Perforce
Change: 184433
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00
Richard Brooksby
a97757482b
Fixing abuses of res and resfail in the splay tree interface.
...
Copied from Perforce
Change: 184432
ServerID: perforce.ravenbrook.com
2014-02-23 10:41:15 +00:00