Page MenuHomeFreeBSD

Pass resize parameter to vm_map_entry_resize_free
ClosedPublic

Authored by dougm on May 22 2019, 4:33 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 8 2024, 7:55 PM
Unknown Object (File)
Dec 20 2023, 3:40 AM
Unknown Object (File)
Nov 13 2023, 12:25 AM
Unknown Object (File)
Nov 7 2023, 1:25 AM
Unknown Object (File)
Nov 4 2023, 4:59 PM
Unknown Object (File)
Oct 31 2023, 8:56 AM
Unknown Object (File)
Oct 6 2023, 11:21 PM
Unknown Object (File)
Oct 6 2023, 12:27 AM
Subscribers

Details

Summary

This is a small piece broken off of the change under review at D19826. Passing a parameter to vm_map_entry_resize_free that describes the amount of resizing reduces the number of functions changing the vm_map invariants regarding the max_free field of map entries.

Test Plan

I've tested with a test program that pounds the vm_map and seen no obvious performance impact from this change.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Other than the note about if()s, this looks fine.

vm_map.c
4325 ↗(On Diff #57701)

I find this nesting of if()s cleaner than repeated condition in your variant. It is clear that we do some cleanup, and the kind of cleanup depends on gap_deleted.

Restore indentation. Wrap long line.

vm_map.c
4353 ↗(On Diff #57703)

Did you delete the wrong line?

Fix the conflict with the old patch correctly, this time.

dougm added inline comments.
vm_map.c
4353 ↗(On Diff #57703)

Yep.

kib added inline comments.
vm_map.c
1254 ↗(On Diff #57704)

I think the type should be vm_size_t but I see that I myself used it inconsistently.

This revision is now accepted and ready to land.May 22 2019, 5:35 PM
This revision was automatically updated to reflect the committed changes.
dougm marked an inline comment as done.