Page MenuHomeFreeBSD

Virtual MemoryGroup
ActivePublic

Watchers

  • This project does not have any watchers.
  • View All

Recent Activity

Tue, Nov 17

alc added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

I see that I have misunderstood your intent.

Once upon a time, a vm_entry had fields left and right, for membership in a tree, and fields next and prev, for membership in a linked list. This consistency code checked to ensure that everything in the list was also in the tree. Then I threaded the tree and eliminated the list, and mechanically changed the consistency checks that used next and prev to use tree operations instead. I did not consider, then, that there was no longer any point in checking everything in the list for tree membership, since the list is now the tree and they can't be inconsistent.

Since everything being checked here is set in the SPLAY_LEFT_STEP and SPLAY_RIGHT_STEP macros, this is really just a correctness test for the splay tree implementation. It is no longer a check to see whether the programmer manipulating a tree, a list, and some size fields kept them in a consistent state. So I suggest that discarding the check makes more sense than optimizing it.

Tue, Nov 17, 8:14 PM · Virtual Memory

Oct 20 2026

dougm added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

I see that I have misunderstood your intent.

Oct 20 2026, 10:16 PM · Virtual Memory
nprice added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

Here's a reproducer https://people.freebsd.org/~nprice/forkmap.c

Oct 20 2026, 8:02 PM · Virtual Memory
nprice added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

The initial statement, "The DIAGNOSTIC consistency walk searches the tree from the root for every entry", is false. The implementation of vm_map_entry_succ(), used in VM_MAP_ENTRY_FOREACH, makes no reference to the "root" member of the vm_map struct.

vm_map_entry_succ takes a step to the right child, then steps left until the left child reaches back to the original entry. As this is a threaded tree, this means that every pointer in the tree will be examined once in the course of walking the whole tree. In a threaded tree, there are no null pointers; where a standard tree would have a null pointer, the threaded tree has instead a pointer to the previous (left) or next (right) tree element, or to the "header" node at the lower and upper bounds of the tree.

So I fail to see what this change will achieve.

Oct 20 2026, 7:30 PM · Virtual Memory
dougm added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

The initial statement, "The DIAGNOSTIC consistency walk searches the tree from the root for every entry", is false. The implementation of vm_map_entry_succ(), used in VM_MAP_ENTRY_FOREACH, makes no reference to the "root" member of the vm_map struct.

Oct 20 2026, 6:24 PM · Virtual Memory
alc added a comment to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

@dougm needs to look at this.

Oct 20 2026, 5:11 PM · Virtual Memory

Oct 19 2026

markj added reviewers for D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork: alc, dougm, kib.
Oct 19 2026, 1:44 PM · Virtual Memory

Oct 18 2026

nprice added inline comments to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.
Oct 18 2026, 6:57 PM · Virtual Memory
nprice updated the diff for D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.

only reserve stack space (~1k) during check

Oct 18 2026, 6:46 PM · Virtual Memory
adrian added inline comments to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork.
Oct 18 2026, 5:10 PM · Virtual Memory
adrian added a project to D60841: diagnostic: avoid a quadratic vm_map consistency walk after fork: Virtual Memory.
Oct 18 2026, 5:08 PM · Virtual Memory

May 1 2026

kib closed D56725: uipc_shm.c: make large page allocation interruptible.
May 1 2026, 1:16 AM · Virtual Memory

Apr 30 2026

markj accepted D56725: uipc_shm.c: make large page allocation interruptible.
Apr 30 2026, 4:48 PM · Virtual Memory
emaste set the icon for Virtual Memory to Group.
Apr 30 2026, 4:36 PM
adrian added a project to D56725: uipc_shm.c: make large page allocation interruptible: Virtual Memory.
Apr 30 2026, 4:35 PM · Virtual Memory
emaste created Virtual Memory.
Apr 30 2026, 4:34 PM