forked from apache/kudu
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
diskrowset: stop using percpu_rwlock
In a heap analysis of a server with 34K rowsets, I see percpu_rwlocks inside DiskRowSet taking ~105MB of memory. Each percpu_rwlock is using 48 cache lines (3072 bytes) so the multiplication works out to around the same value as I see in practice. Although switching to a normal rwlock might increase contention marginally, it's probably worth it for the 100MB memory win. If we start to see contention here in a workload we can figure out other ways to avoid taking the locks, but my guess is that the improved cache locality of the lock being stored inline in the DRS class will outweigh any contention-related issue. Change-Id: I9e210eb3e8fc13d807f6630e68c68d64902b1cc4 Reviewed-on: http://gerrit.cloudera.org:8080/6472 Tested-by: Kudu Jenkins Reviewed-by: Mike Percy <[email protected]>
- Loading branch information
1 parent
c3953ad
commit 286de53
Showing
2 changed files
with
11 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters