swap: THP optimizing refactoring
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest8 patches 0 repliesNew
- v38 patches 5 repliesSuperseded
- v2 posting 2/27 patches 11 repliesSuperseded
Earlier versions · 2
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v2 posting 1/2 | 0 of 7 patches | 0 replies | Superseded | |
| v1 | 6 patches | 8 replies | Superseded |
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/8 | swap: Add comments to lock_cluster_or_swap_info()mm/ | +7 | 0 replies | |
| 2/8 | mm/swapfile.c: Replace some #ifdef with IS_ENABLED()mm/ | +20 | 0 replies | |
| 3/8 | swap: Use swap_count() in swap_page_trans_huge_swapped()mm/ | +2 | 0 replies | |
| 4/8 | swap: Unify normal/huge code path in swap_page_trans_huge_swapped()mm/ | +3 | 0 replies | |
| 5/8 | swap: Unify normal/huge code path in put_swap_page()mm/ | +37 | 0 replies | |
| 6/8 | swap, get_swap_pages: Use entry_size instead of cluster in parameterinclude/ mm/ mm/ | +13 | 0 replies | |
| 7/8 | swap: Add __swap_entry_free_locked()mm/ | +14 | 0 replies | |
| 8/8 | swap, put_swap_page: Share more between huge/normal code pathmm/ | +10 | 0 replies |
Reviews trailers per patch
All 8 patches have a Reviewed-by or Acked-by.
| Patch | Dave Hansen | Daniel Jordan |
|---|---|---|
| 1/8 | Suggested-and-acked-by | R-b |
| 2/8 | Suggested-and-acked-by | R-b |
| 3/8 | A-b | Suggested-and-reviewed-by |
| 4/8 | Suggested-and-acked-by | R-b |
| 5/8 | Suggested-and-acked-by | R-b |
| 6/8 | A-b | |
| 7/8 | A-b | R-b |
| 8/8 | A-b | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v4 0/8] swap: THP optimizing refactoring
This patchset is based on 2018-07-13 head of mmotm tree.
Now the THP (Transparent Huge Page) swap optimizing is implemented in the way like below,
#ifdef CONFIG_THP_SWAPhuge_function(...)
{
}
#elsenormal_function(...)
{
}
#endif
general_function(...)
{
if (huge)
return thp_function(...);
else
return normal_function(...);
}As pointed out by Dave Hansen, this will,
1. Created a new, wholly untested code path for huge page
2. Created two places to patch bugs
3. Are not reusing code when possible
This patchset is to address these problems via merging huge/normal code path/functions if possible.
One concern is that this may cause code size to dilate when !CONFIG_TRANSPARENT_HUGEPAGE. The data shows that most refactoring will only cause quite slight code size increase.
Best Regards,
Huang, Ying