Page MenuHomeFreeBSD

dougm (Doug Moore)
User

Projects

User does not belong to any projects.

User Details

User Since
Jun 30 2017, 3:18 PM (133 w, 3 d)

Tauist. Bit twiddler. Advocate for continued logarithms.

Recent Activity

Today

dougm accepted D23282: Move readahead into its own function..
Mon, Jan 20, 8:21 PM

Sat, Jan 18

dougm added inline comments to D23189: Fix definition and use of RB_AUGMENT.
Sat, Jan 18, 5:58 PM
dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Push the setting of a->entry->start down into dmar_gas_match_one. Add a documentary comment before that function.

Sat, Jan 18, 5:57 PM
dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Fix the upper limits passed to dmar_gas_match_one from dmar_gas_uppermatch.

Sat, Jan 18, 7:35 AM

Fri, Jan 17

dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Stop sending the prev entry to dmar_gas_match_insert. I was sending the prev entry sometimes and the next entry sometimes, but the insert function was only using them for assertion checking anyway.

Fri, Jan 17, 4:45 PM
dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Update assertion code to test first and last, rather than free_after.

Fri, Jan 17, 3:52 PM
dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Rework intel_gas.c more than I had planned. Along with free_down, keep a first and last value for each entry describing the least and greatest value in the subtree rooted there. Update these in the augment routine. In lowermatch, look for the fit with greatest address less than the lowaddr, which I understand to be an upper bound on the address. In uppermatch, duplicate the lowermatch code, looking for the fit with least address greater than highaddr, which I understand to be a lower bound on the address.

Fri, Jan 17, 8:43 AM

Thu, Jan 16

dougm updated the diff for D23189: Fix definition and use of RB_AUGMENT.

Correct the augmentation after RB_INSERT so that the newly inserted node is augmented too, before its parent.

Thu, Jan 16, 5:17 PM
dougm added a comment to D23189: Fix definition and use of RB_AUGMENT.
In D23189#508661, @kib wrote:

If RB_ code would do the walk, I am fine with it.
Did you tested this on a machine with DMAR enabled ? You may ask Peter, long-running high-load networking tests exercise the GAS allocator quite efficiently.

Thu, Jan 16, 4:11 PM
dougm updated subscribers of D23189: Fix definition and use of RB_AUGMENT.
Thu, Jan 16, 4:10 PM

Wed, Jan 15

dougm updated the summary of D23189: Fix definition and use of RB_AUGMENT.
Wed, Jan 15, 3:35 PM
dougm created D23189: Fix definition and use of RB_AUGMENT.
Wed, Jan 15, 9:19 AM

Thu, Jan 2

dougm updated the diff for D22987: Define a function combining vm entry lookup and clip-start.

Add an important omitted line.

Thu, Jan 2, 9:35 PM

Wed, Jan 1

dougm created D22987: Define a function combining vm entry lookup and clip-start.
Wed, Jan 1, 7:48 AM

Tue, Dec 31

dougm committed rS356243: The map-entry clipping functions modify start and end entries of an.
The map-entry clipping functions modify start and end entries of an
Tue, Dec 31, 10:21 PM
dougm closed D22897: clip without corrupting map.
Tue, Dec 31, 10:21 PM

Mon, Dec 30

dougm updated the diff for D22897: clip without corrupting map.

Add comments.

Mon, Dec 30, 10:17 PM

Sun, Dec 29

dougm added a comment to D22897: clip without corrupting map.

Yes I think it should be fixed by r355985. At least, the bug fixed in r355985 could cause this panic. This is a VMIO buffer and so should contain managed pages.

Sun, Dec 29, 10:01 PM

Fri, Dec 27

dougm committed rS356131: MFC r355913.
MFC r355913
Fri, Dec 27, 5:56 PM
dougm committed rS356130: MFC r355913.
MFC r355913
Fri, Dec 27, 5:42 PM

Sun, Dec 22

dougm committed rS356028: Fix typo using RB_INITIALIZER..
Fix typo using RB_INITIALIZER.
Sun, Dec 22, 9:53 PM
dougm added a reviewer for D22897: clip without corrupting map: markj.
Sun, Dec 22, 5:07 PM
dougm added a comment to D22897: clip without corrupting map.
In D22897#501357, @pho wrote:

With D22897.65888.diff I got this after 5 hours:

Sun, Dec 22, 1:40 AM

Dec 21 2019

dougm added a reviewer for D22897: clip without corrupting map: alc.
Dec 21 2019, 5:36 PM
dougm created D22897: clip without corrupting map.
Dec 21 2019, 6:53 AM

Dec 20 2019

dougm planned changes to D22777: clip within the subtree rooted at entry.

This approach has a fatal flaw. It may be impossible to distinguish parent from child without a complete search-from-root.

Dec 20 2019, 7:22 PM

Dec 19 2019

dougm accepted D22886: Remove some unused functions..
Dec 19 2019, 11:22 PM
dougm committed rS355913: Including <sys/tmpfs.h> into non-kernel software leads to a.
Including <sys/tmpfs.h> into non-kernel software leads to a
Dec 19 2019, 4:40 PM
dougm closed D22874: make tmpfs.h friendly with _KERNEL undefined.
Dec 19 2019, 4:40 PM
dougm updated the diff for D22874: make tmpfs.h friendly with _KERNEL undefined.

Remove #include <sys/lock.h> from tmpfs.h.

Dec 19 2019, 4:20 PM
dougm created D22874: make tmpfs.h friendly with _KERNEL undefined.
Dec 19 2019, 4:16 AM

Dec 18 2019

dougm updated the diff for D22777: clip within the subtree rooted at entry.

Add in the next planned change - the fix of the max_free test cases at the start of SPLAY_{LEFT,RIGHT}_STEP.

Dec 18 2019, 6:39 AM
dougm added a comment to D21964: Make vm_map a threaded tree.

Sounds good, lets go with your patch then.
I closed my merge request on the GNOME GitLab.

Dec 18 2019, 3:52 AM

Dec 17 2019

dougm added a comment to D21964: Make vm_map a threaded tree.

@dougm Your patch surely does look cleaner than mine (I just needed something to unbreak the build), but are you sure it will work on 12.x and 11.x? If so, lets go with yours.
I built my patch to (hopefully) be compatible with 12.x and 11.x, so that's why it looks ugly, it has #ifdefs. I don't know if 12.x and below has vm_map_entry_read_succ().

Dec 17 2019, 11:05 PM
dougm added a comment to D21964: Make vm_map a threaded tree.

I integrated your changes. Would the updated Ports/GNOME changes work?

Dec 17 2019, 10:21 PM
dougm added a comment to D21964: Make vm_map a threaded tree.

I sent an updated patch to the GNOME people here: https://gitlab.gnome.org/GNOME/libgtop/merge_requests/12
I also have an fixed Bugzilla patch here: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=242533

Dec 17 2019, 5:46 PM
dougm added a comment to D21964: Make vm_map a threaded tree.

This change broke devel/libgtop on powerpc64 (I didn't try amd64, it could also break there). The error is:

procmap.c:282:39: error: no member named 'next' in 'struct vm_map_entry'
        first = vmspace.vm_map.header.next;
Dec 17 2019, 5:02 AM
dougm updated subscribers of D21964: Make vm_map a threaded tree.
Dec 17 2019, 4:52 AM

Dec 16 2019

dougm added a comment to D21964: Make vm_map a threaded tree.

A similar problem arose in lib/libprocstat/libprocstat.c and was
addressed in the most recent change to that file.  I'll look at this
problem tonight, and expect to find that a similar solution will suffice.

Dec 16 2019, 9:32 PM

Dec 15 2019

dougm added a reviewer for D22777: clip within the subtree rooted at entry: alc.
Dec 15 2019, 9:58 PM
dougm added inline comments to D22820: Move the fault busy sleep into its own function..
Dec 15 2019, 3:06 AM

Dec 14 2019

dougm updated the diff for D22777: clip within the subtree rooted at entry.

Rework the path compression so that there's no need to consider entries not strictly between entry and next_entry (or prev_entry).

Dec 14 2019, 10:17 PM
dougm closed D22666: Simplify leaf_alloc, improve some hints.
Dec 14 2019, 7:44 PM
dougm committed rS355757: Simplify the processing a leaf mask to find big-enough ranges of set.
Simplify the processing a leaf mask to find big-enough ranges of set
Dec 14 2019, 7:44 PM
dougm updated the diff for D22777: clip within the subtree rooted at entry.

Carefully pick the end-of-list marker before starting the walk toward a successor in clip_end.

Dec 14 2019, 7:38 PM
dougm updated the diff for D22777: clip within the subtree rooted at entry.

Fix failure to update map->nentries. Fix problem updating max_free when entry and successor/predecessor are parent and child in the tree. Do path-halving when taking more than one step to find the successor/predecessor to avoid walking long paths when the same entry is clipped one piece at a time repeatedly.

Dec 14 2019, 4:41 AM

Dec 13 2019

dougm updated the diff for D22666: Simplify leaf_alloc, improve some hints.

Apply reviewer's suggestions.

Dec 13 2019, 4:51 AM

Dec 12 2019

dougm added inline comments to D22777: clip within the subtree rooted at entry.
Dec 12 2019, 4:26 PM
dougm added inline comments to D22777: clip within the subtree rooted at entry.
Dec 12 2019, 4:07 PM
dougm updated the diff for D20625: clarify reserv_test_config.

Resolve merge conflicts.

Dec 12 2019, 8:07 AM
dougm abandoned D20368: Let vm_map_link handle new entries that clip old ones.
Dec 12 2019, 7:55 AM
dougm abandoned D20664: Changes to vm_map_lookup_entry.

Completing the threading of the vm_map splay tree makes this pointless.

Dec 12 2019, 7:53 AM
dougm created D22777: clip within the subtree rooted at entry.
Dec 12 2019, 5:14 AM

Dec 11 2019

dougm closed D22760: Factor out common clipping code.
Dec 11 2019, 4:10 PM
dougm committed rS355612: Extract code common to _vm_map_clip_start and _vm_map_clip_end into a.
Extract code common to _vm_map_clip_start and _vm_map_clip_end into a
Dec 11 2019, 4:10 PM
dougm created D22760: Factor out common clipping code.
Dec 11 2019, 7:37 AM

Dec 9 2019

dougm added a comment to D22324: try to free blocks by upgrading object locks.
In D22324#490910, @kib wrote:

I am somewhat curious how much does the upgrade succeed. Did you measured it ? E.g. the counters of total vm_pager_page_unswapped calls during buildworld vs. the number of times the lock needs to be upgraded vs. the number of successfull upgrades.

Dec 9 2019, 3:40 PM
dougm committed rS355552: Revert r355505. The code that it allowed to compile has been removed..
Revert r355505. The code that it allowed to compile has been removed.
Dec 9 2019, 5:09 AM

Dec 8 2019

dougm committed rS355538: Define a vm_map method for user-space for advancing from a map entry.
Define a vm_map method for user-space for advancing from a map entry
Dec 8 2019, 10:34 PM
dougm closed D22728: Fix procstat kvm_read issues.
Dec 8 2019, 10:34 PM
dougm updated the diff for D22728: Fix procstat kvm_read issues.

Make more clear that the new function is not used by the kernel.

Dec 8 2019, 9:23 PM
dougm added a comment to D22728: Fix procstat kvm_read issues.
In D22728#497480, @kib wrote:

I was bitten by use of seemingly kernel-only headers in userspace too many times. I believe that it is much better to not try to adapt vm/vm_map.h inlines to userspace, but have separate code in libprocstat, as Mark suggested.

Dec 8 2019, 9:17 PM
dougm updated the diff for D22728: Fix procstat kvm_read issues.

Add comment. Change vm_map_entry_read_succ so that it leaves the next entry in vmentry, and doesn't only return the pointer to that entry.

Dec 8 2019, 7:40 PM
dougm added a comment to D22728: Fix procstat kvm_read issues.

I don't have an objection to this approach, but it's kind of unusual when compared with other routines which use libkvm. That is, I would just implement entry_read_succ directly in libprocstat. With this patch, libprocstat still embed details of the implementation (such as the fact that iteration terminates after visiting the header) so we still do not get a clean separation between userspace and the kernel, and vm_map_entry_read_succ() is harder to understand because of the indirection through "reader".

Dec 8 2019, 6:38 PM
dougm added a reviewer for D22728: Fix procstat kvm_read issues: kib.
Dec 8 2019, 6:06 PM
dougm retitled D22728: Fix procstat kvm_read issues from Fix procstat mmap issues to Fix procstat kvm_read issues.
Dec 8 2019, 8:10 AM
dougm updated the diff for D22728: Fix procstat kvm_read issues.

Fix compilation errors.

Dec 8 2019, 8:05 AM
dougm created D22728: Fix procstat kvm_read issues.
Dec 8 2019, 12:23 AM

Dec 7 2019

dougm committed rS355502: Fix a type error in fixing libprocstat to be compatible with vm_map changes..
Fix a type error in fixing libprocstat to be compatible with vm_map changes.
Dec 7 2019, 6:41 PM
dougm closed D22726: fixing libprocstat fix.
Dec 7 2019, 6:41 PM
dougm created D22726: fixing libprocstat fix.
Dec 7 2019, 6:21 PM
dougm committed rS355501: r355491 broke compilation of libprocstat.c. Change that code to use.
r355491 broke compilation of libprocstat.c. Change that code to use
Dec 7 2019, 6:16 PM
dougm closed D22725: Fix libprocstat.
Dec 7 2019, 6:16 PM
dougm created D22725: Fix libprocstat.
Dec 7 2019, 6:01 PM
dougm committed rS355491: Remove the next and prev fields from vm_map_entry, to save a bit of.
Remove the next and prev fields from vm_map_entry, to save a bit of
Dec 7 2019, 5:14 PM
dougm closed D21964: Make vm_map a threaded tree.
Dec 7 2019, 5:14 PM

Dec 6 2019

dougm updated the diff for D21964: Make vm_map a threaded tree.

Update base to r355439. Stop passing dereferenced pointers to SPLAY_{LEFT,RIGHT}_STEP macros, since it seems that the compiler can't avoid extra operations for possible aliasing.

Dec 6 2019, 9:19 AM

Dec 5 2019

dougm added a comment to D21964: Make vm_map a threaded tree.

Thanks. To be clear, "old" is unmodified sources, "new" is the patch but with next and prev pointers retained, and "new, thread-only" is this patch?

Dec 5 2019, 6:22 PM
dougm added a comment to D21964: Make vm_map a threaded tree.

How are you collecting performance counters in your benchmark? Would it also be possible to collect branch miss and CPI statistics?

Dec 5 2019, 4:09 AM

Dec 4 2019

dougm accepted D22682: bistring: avoid gcc -Wsign-compare.
Dec 4 2019, 8:07 PM
dougm accepted D22678: Fix an off-by-one in vm_map_pmap_enter()..
Dec 4 2019, 5:45 PM
dougm created D22666: Simplify leaf_alloc, improve some hints.
Dec 4 2019, 6:04 AM
dougm committed rS355377: Change the implementation of bit_ffc_area_at so that, in the worst.
Change the implementation of bit_ffc_area_at so that, in the worst
Dec 4 2019, 3:37 AM
dougm closed D22523: Avoid finding every bit transition in bit_ffs_area_at.
Dec 4 2019, 3:37 AM

Dec 3 2019

dougm added a comment to D22523: Avoid finding every bit transition in bit_ffs_area_at.

With the attached simple test program, compiled with -O3, the results without and with DM defined are:

Dec 3 2019, 3:26 AM

Dec 2 2019

dougm committed rS355296: MFC r348749 - Speed-up vm_reserv_reclaim_config..
MFC r348749 - Speed-up vm_reserv_reclaim_config.
Dec 2 2019, 5:28 PM
dougm updated the summary of D21964: Make vm_map a threaded tree.
Dec 2 2019, 7:39 AM
dougm updated the diff for D21964: Make vm_map a threaded tree.

Apply reviewer suggestions. Modify SPLAY_{LEFT,RIGHT}_STEP to address performance issues. Update timing results. More than have the time lost is recovered. The rest is likely due to the cost of successor and predecessor.

Dec 2 2019, 7:33 AM

Nov 30 2019

dougm updated the summary of D21964: Make vm_map a threaded tree.
Nov 30 2019, 12:02 AM

Nov 29 2019

dougm updated the summary of D21964: Make vm_map a threaded tree.
Nov 29 2019, 7:56 PM
dougm updated the summary of D21964: Make vm_map a threaded tree.
Nov 29 2019, 7:55 PM
dougm updated the summary of D21964: Make vm_map a threaded tree.
Nov 29 2019, 9:40 AM
dougm updated the diff for D21964: Make vm_map a threaded tree.

Update to account for the fact that several parts originally in this patch have now been checked in. They were the parts that let me show a little time improvement, and what's left here, about nothing but threading the tree, will probably give back some of that time saved. I'll update the timing results and cache miss results in a while.

Nov 29 2019, 6:11 AM
dougm committed rS355201: Functions that call vm_map_splay_merge sometimes set data fields.
Functions that call vm_map_splay_merge sometimes set data fields
Nov 29 2019, 2:07 AM
dougm closed D22589: break up vm_map_splay_merge.
Nov 29 2019, 2:07 AM

Nov 28 2019

dougm updated the diff for D22589: break up vm_map_splay_merge.

Incrementing the nupdates counter, which matters only when DIAGNOSTICS is #defined, fell out of the previous version. Add it back in, in a new and better place.

Nov 28 2019, 5:46 PM
dougm created D22589: break up vm_map_splay_merge.
Nov 28 2019, 6:03 AM

Nov 27 2019

dougm closed D22544: Use macros to search vm_map.
Nov 27 2019, 9:01 PM
dougm committed rS355147: Inline some splay helper functions to improve performance on a.
Inline some splay helper functions to improve performance on a
Nov 27 2019, 9:00 PM
dougm added a comment to D22544: Use macros to search vm_map.
In D22544#493747, @alc wrote:

Can you explain why this change reduces the number of L1 data cache misses?

Nov 27 2019, 8:48 PM