Page MenuHomeFreeBSD

Fix arc after kmem/kernel_arena merge

Authored by jeff on Dec 14 2017, 9:37 PM.



kernel_arena doesn't have the same initial size constraint as kmem did. This broke some of the arena logic in arc. Setting a limit on kernel_arena would produce other undesirable results and complications. Instead, I opted to use the uma limit feature directly. This required some FreeBSD specific ifdefs.

Test Plan

pho reports it is stable and no longer has a perf regression relatively to pre change.

Diff Detail

rS FreeBSD src repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

jeff created this revision.Dec 14 2017, 9:37 PM
markj accepted this revision.Dec 17 2017, 8:06 PM
This revision is now accepted and ready to land.Dec 17 2017, 8:06 PM
avg added inline comments.Dec 20 2017, 6:03 PM
4293 ↗(On Diff #36614)

I'd suggest not adding this new ifdef and instead moving zio_area definition to be alongside heap_arena in sys/cddl/compat/opensolaris/sys/kmem.h. If I correctly understand, now it will always be NULL on FreeBSD.

4337 ↗(On Diff #36614)

This is FreeBSD-specific code. It's not present upstream at all.
It was added by @mav in rS281109 and then transformed to the current shape when a big ZFS change was imported in rS286625.
So, if we really think that that kind of check is not needed any longer in ARC, then this block and all traces of FMR_ZIO_FRAG can just be removed.

avg added inline comments.Dec 20 2017, 6:05 PM
4337 ↗(On Diff #36614)

The original commit is rS281026, actually.

jeff marked 2 inline comments as done.Jan 1 2018, 12:44 AM
This revision was automatically updated to reflect the committed changes.