vfs: Use dlock list for SB's s_inodes list
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v9 Latest5 patches 5 repliesIn review
- v86 patches 14 repliesSuperseded
- v76 patches 17 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v6 | 6 patches | 9 replies | Superseded |
Changes in v9 from the cover letter
- The last 2 patches in v8 were dropped because there is no more user that can use them.
- Include Davidlohr's dlock_lists_empty() scaling patch.
- Rebase the code to 4.19-rc3.
Patches in v9 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | lib/dlock-list: Distributed and lock-protected listsinclude/ lib/ lib/ | +477 | 0 replies | |
| 2/5 | vfs: Remove unnecessary list_for_each_entry_safe() variantsfs/ | +4 | 0 replies | |
| 3/5 | vfs: Use dlock list for superblock's inode listfs/ fs/ fs/ +4 more | +39 | 2 replies | |
| 4/5 | lib/dlock-list: Make sibling CPUs share the same linked listlib/ | +59 | 0 replies | |
| 5/5 | lib/dlock-list: Scale dlock_lists_empty()include/ lib/ | +65 | 3 replies |
Reviews trailers per patch
4 of 5 patches have a Reviewed-by or Acked-by.
| Patch | Jan Kara | Waiman Long |
|---|---|---|
| 1/5 | R-b | |
| 2/5 | ||
| 3/5 | R-b | |
| 4/5 | R-b | |
| 5/5 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v9 0/5] vfs: Use dlock list for SB's s_inodes list
v8->v9:
- The last 2 patches in v8 were dropped because there is no more user that can use them.
- Include Davidlohr's dlock_lists_empty() scaling patch.
- Rebase the code to 4.19-rc3.
v8 patch: https://lkml.org/lkml/2017/10/31/776
This patchset has been dormant for almost a year. Now I am going to restart it again.
This patchset provides new APIs for a set of distributed locked lists (one/CPU core) to minimize lock and cacheline contention. Insertion and deletion to the list will be cheap and relatively contention free. Lookup, on the other hand, may be a bit more costly as there are multiple lists to iterate. This is not really a problem for the replacement of superblock's inode list by dlock list included in the patchset as lookup isn't needed.
Patch 1 introduces the dlock list. The list heads are allocated by kcalloc() instead of percpu_alloc(). Each list head entry is cacheline aligned to minimize contention.
Patch 2 replaces the use of list_for_each_entry_safe() in evict_inodes() and invalidate_inodes() by list_for_each_entry().
Patch 3 modifies the superblock and inode structures to use the dlock list. The corresponding functions that reference those structures are modified.
Patch 4 makes the sibling CPUs use the same dlock list head to reduce the number of list heads that need to be iterated.
Patch 5 improves the performance of dlock_lists_empty() call.
See patch 3 for some performance data for this patchset.
Davidlohr Bueso (1):
lib/dlock-list: Scale dlock_lists_empty()
Jan Kara (1):
vfs: Remove unnecessary list_for_each_entry_safe() variants
Waiman Long (3):
lib/dlock-list: Distributed and lock-protected lists
vfs: Use dlock list for superblock's inode list lib/dlock-list: Make sibling CPUs share the same linked list
fs/block_dev.c | 9 +- fs/drop_caches.c | 9 +- fs/inode.c | 38 +++--- fs/notify/fsnotify.c | 9 +- fs/quota/dquot.c | 14 +- fs/super.c | 7 +- include/linux/dlock-list.h | 250 ++++++++++++++++++++++++++++++++++ include/linux/fs.h | 8 +- lib/Makefile | 2 +- lib/dlock-list.c | 325 +++++++++++++++++++++++++++++++++++++++++++++ 10 files changed, 617 insertions(+), 54 deletions(-) create mode 100644 include/linux/dlock-list.h create mode 100644 lib/dlock-list.c
Signature · 1 line
1.8.3.1