Page MenuHomeFreeBSD

(umaperf 4/7) Use a separate lock for the zone and keg.
ClosedPublic

Authored by jeff on Dec 15 2019, 11:38 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Apr 18, 6:26 PM
Unknown Object (File)
Sat, Apr 18, 6:26 PM
Unknown Object (File)
Sat, Apr 18, 4:20 PM
Unknown Object (File)
Thu, Apr 16, 11:11 PM
Unknown Object (File)
Thu, Apr 16, 11:28 AM
Unknown Object (File)
Mon, Apr 6, 4:17 PM
Unknown Object (File)
Sun, Apr 5, 11:40 AM
Unknown Object (File)
Mon, Mar 30, 2:19 PM
Subscribers

Details

Summary

This is part of a series of patches intended to enable first-touch numa policies for UMA by default. It also reduces the cost of uma_zalloc/zfree by approximately 30% each in my tests.

Zone lock protected a few random things that did not provide any real protection so I eliminated them. Now zone lock effectively synchronizes the bucket lists and counts. So it is used in the cache_alloc()/cache_free() path but not below. These holds are all very short. If this lock is still shown to be contending we could further break the zone lock up by domain with a little effort in the bucket accounting.

This helps with crossdomain free because you may have to drain buckets back to the keg layer. This process will now not hold-up the normal allocation/free path. The introduction of uz_import/uz_release also broke any strong relationship between these two layers.

Diff Detail

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