Page MenuHomeFreeBSD

allow epochs to compose
ClosedPublic

Authored by mmacy on Jun 29 2018, 6:22 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Apr 20, 7:54 AM
Unknown Object (File)
Mar 20 2024, 12:27 AM
Unknown Object (File)
Mar 19 2024, 10:18 AM
Unknown Object (File)
Mar 18 2024, 2:39 AM
Unknown Object (File)
Mar 18 2024, 2:39 AM
Unknown Object (File)
Mar 18 2024, 2:39 AM
Unknown Object (File)
Mar 18 2024, 2:39 AM
Unknown Object (File)
Mar 18 2024, 2:39 AM

Details

Summary
  • add tracker argument to preemptible epochs
  • make epoch read path inline in kernel
  • change in_epoch to take an epoch as argument
Test Plan

pho + llnw canary

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 17828

Event Timeline

mmacy retitled this revision from src to allow epochs to compose.Jun 29 2018, 6:23 PM
mmacy edited the summary of this revision. (Show Details)
mmacy edited the test plan for this revision. (Show Details)
mmacy added reviewers: jeff, markj.
mmacy added a subscriber: kbowling.
sys/conf/kern.post.mk
188 ↗(On Diff #44650)

Will we be able to use epochs in modules?

sys/conf/kern.post.mk
188 ↗(On Diff #44650)

Yes. See the _KBI functions in epoch.h. Much like locks and atomics there's no provision for in-tree modules to use the inline variants. I hope to address that at some point.

  • fix cast
  • add dumponfail option to in_epoch
  • use dynamically generated thread_global to eliminate proc.h dependencies
sys/conf/kern.post.mk
188 ↗(On Diff #44650)

Modules wanting inline atomics, locks, and epoch sections can define KLD_BASE. So far I've only done it for rack and fastpath but it may make sense for ZFS and the 100G drivers.

  • rack fixes
  • eliminate redundant acquisitions
  • eliminate ti_locked branchfest in do_segment, rack, and fastpath
  • replace all INP_INFO_{RLOCK, RUNLOCK} with explicit epoch_tracker usage
  • restore TIMEWAIT checks at close
  • don't drop reference in lock del as we're no longer adding a ref prior
  • rebase
  • cleanups
  • rebase to inline critical
kbowling added a subscriber: jtl.

We've tested this in synthetic stress testing and production load at LLNW. This is a wide reaching change and has higher chance for fallout, but I think getting additional public testing in HEAD will be the most prudent use of time to stabilize the KPI and implementation for 12.0-RELEASE.

@jtl for NF there are some minor mechanical changes that will be needed for your out of tree stacks.

This revision is now accepted and ready to land.Jul 4 2018, 2:30 AM