- User Since
- Jun 30 2017, 3:18 PM (76 w, 4 d)
Thu, Dec 13
Treat the header node as NULL in findspace, just as it is treated that way in vm_map_entry_set_max_free.
Wed, Dec 12
Treat the sentinel node as a NULL for computing max_free values.
Rebuild on top of a working-again D13999 patch.
Dare to change unlink again to walk the right spine also, and try to put the pieces together again afterward.
Fix dumb error in the last one.
Tue, Dec 11
Just change the processing of the left spine a wee bit from what worked before, and see if that breaks.
Just change unlink from the last working version by walking the left and right spines of the found node, without relying on splay_split to do it, and find the new root after that.
Use sysctl to make stats available. Update stats atomically.
Handle the special case of deleting the max entry.
Mon, Dec 10
Add null checks for root children in vm_map_entry_unlink.
Sun, Dec 9
Reduce the code size in unlink by reusing splay_split.
Combine the splay-sentinel patch with the patch that drops the adj_free field from vm_map_entry.
Sat, Dec 8
Apply reviewer suggestions.
Fri, Dec 7
Adopt style suggestions. Slightly improve the quality of the bighint for this special case.
Tue, Dec 4
Dropped from phabricator. Added to subr_blist super-patch email spam.
Dropping from phabricator. Adding to subr_blist super-patch email-spam.
Dropping from phabricator. Part of the subr_blist super-patch to be emailed instead.
Removed from phabricator. Available by email.
Mon, Dec 3
These changes have served their purpose in debugging subr_list.c problems, so they're being discarded.
Sun, Dec 2
Sat, Dec 1
Abandon attempts to make callers of vm_map_lookup_entry adhere to range limits on their address inquires, and just go back to having vm_map_lookup_entry check for out-of-bounds address.
In vm_map_wire, use VM_MAP_RANGE_CHECK before testing start and end for equality, since it might make them equal and let the function exit before a possible lookup for address vm_map_max, which is outside the valid range.
Allow lookups for the address at the upper bound of the map range.
Fri, Nov 30
In vm_fault.c, make sure that vm_map_lookup is not invoked with and invalid address.
Make it compile.
Update a comment. Fix a style issue.
In vm_map_lookup_entry, add a KASSERT to usurp an exit case, so that I can either delete the exit case, or find the caller passing the bad argument that creates the need for the exit case and fix the caller.
Tue, Nov 27
Fix a broken adj_free calculation in _link. Eliminate two gratuitous differences from the original.
The stack trace shows a panic call from subr_blist.c:828. After this change was accepted with revision 340914, that panic line moved from line 828 to line 830. Can you double-check to make sure that you're testing a version that includes this change?
Drop after_where argument from link. Cleanup unlink.
Mon, Nov 26
Restore vm_map_entry_splay with its original arguments. Break its split and merge phases into separate functions, and use those functions, instead of vm_map_entry_splay, to implement link and unlink.
Sat, Nov 24
Allow bighint to be updated for a meta-node where the cursor lies ahead of all nonempty children, or even when there are no nonempty children, since blist_alloc depends on a reduction of the root bighint to allow a failed allocation to finish.
Wed, Nov 21
Tue, Nov 20
In blist_meta_alloc, mask should not be zero. However, if the only free space in a leaf is behind the cursor, then we zero out all the set bits in mask before we start searching it. But if we zero it, we should return failure immediately. Fix that, and see whether that fixes everything else.
Update patch with compile error fix.
Since assertions intended to be triggered by problems in leaf node allocation where not triggered, add an assertion that look for anomalies in meta node allocation.
The previous test strongly suggests a problem in blist_alloc, in a case where the first blocks of a meta-node are allocated. I've added some assertions, which I don't expect to fail, but if they do I'll learn something.
Add more checks on avail count, so that we can determine whether the avail count for the blist is invalidated by a call to a blist operator, or between calls.
Mon, Nov 19
Add KASSERTs to validate often that the stored value of number of free blocks matches a computed value of number of free blocks.
Sun, Nov 18
Don't update bighint on blist_test_free.
make assertion kernel-compatible.
Dump the stats on the 's' stats option, not the 'p' print option, since printing a tree is often many many lines and the stats are lost.
Nov 18 2018
Don't use 'size' for too many different purposes.
Restore what remains of this patch.
If blist_alloc fails in startup, fill everything and free everything to start over.
Nov 17 2018
With a simpler patch that's more reviewer-friendly, and fails mysteriously, and a more complex patch that is reviewer-hostile, but seems to pass tests, and no understanding of why the two behave differently, nudge the broken one towards more complexity, just to see what happens. It's complexity I wanted to introduce eventually, anyway, but maybe it will help now???
Restore a KASSERT, with both arguments included. #define a name for the set of flags that prevent merging.
Nov 16 2018
Add optimizing parens. Drop invalid KASSERT.
Update comment style.
Fix embarrassing type error.
Initialize a value to avoid a compiler failure.
Nov 15 2018
Copy over from the bigger sentinel patch a bounds check in lookup that I didn't think I needed, but maybe I do after all. Add a local lbound variable to lookup to avoid multiple writes via the pointer parameter.
After recovering a root from the left tree in splay, null the right child of the new root so it doesn't point to the right tree.
Updating to adapt changes to surrounding code. Hoping that this code still works.
Restore one &map->header test that perhaps should not have been dropped. Drop one that was dropped in the working, bigger sentinel patch. Update comments.
But don't forget to splay in findspace.
Drop a test from findspace that is no longer needed.
Don't discard non-NULL root after splay search.
Drop a redundant 'root' declaration.
Again, stop pasting in the parts that depend on having a 'map' parameter.
Paste the splay-disassembly code from the other sentinel patch.
Drop the KASSERTS that led compilation to fail. Update the lookup tree search to compare end before start, to avoid stepping left from the sentinel node.
Nov 13 2018
In _link and _unlink, splay on next and previous map entries to ensure that max_free fields for neighbors are updated.
Nov 12 2018
In vm_map_entry_unlink, update the next and prev pointers first, before invoking vm_set_max_free, so that the correct values for the new gap size is computed.
Nov 10 2018
Address reviewer comments on spacing and ummin usage.
Add a missing "that" to a comment.
Prompted by reviewer comments, endeavor to clarify comments regarding data structure layout.
Nov 7 2018
Drop an unneeded variable.
Nov 5 2018
Add timing to vm_map_entry_resize_free.
Delete spurious line.
Nov 2 2018
Update after patch affected surrounding code.
Nov 1 2018
Oct 31 2018
I can change the definition of max_free a bit and git rid of adj_free entirely, so I'll abandon this patch, and do that one instead, someday.