Improve the performance of bitmap_find_next_zero_area_off()
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v8 Latest2 patches 0 repliesNew
- v72 patches 7 repliesSuperseded
- v62 patches 1 replySuperseded
Earlier versions · 5
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v5 | 2 patches | 6 replies | Superseded | |
| v4 | 2 patches | 10 replies | Superseded | |
| v3 | 2 patches | 8 replies | Superseded | |
| v2 | 1 patch | 0 replies | Superseded | |
| v1 | 2 patches | 6 replies | Superseded |
Patches in v8 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | lib: bitmap: add tests for bitmap_find_next_zero_area_off()lib/ lib/ | +55 | 0 replies | |
| 2/2 | lib: bitmap: optimize bitmap_find_next_zero_area_off()lib/ lib/ | +18 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v8 yet.
Cover letter [PATCH v8 0/2] Improve the performance of bitmap_find_next_zero_area_off()
Use lib/find_bit_benchmark.c for testing. Test results showed a 40% improvement in dense cases, and almost no change in sparse cases.
Performance test results on my hardware:
before(ns) after(ns) change p-value
dense 1211 688 -43.2% 8.3e-11
sparse 13.3 13.4 0.8% 0.27
Version 8 improve test code.
When original bitmap_find_next_zero_area_off() fails, it returns end, where end is greater than size. Therefore, patch1 should use >. expect_eq_uint(1,
bitmap_find_next_zero_area_off(bmap, 192, 0, 33, 0, 0) > 192);
When new bitmap_find_next_zero_area_off() fails, it returns size. Therefore, patch2 should be changed to =. expect_eq_uint(192,
bitmap_find_next_zero_area_off(bmap, 192, 0, 33, 0, 0));
---
v7: https://lore.kernel.org/all/[email protected]
- Only changed the alignment format of the test code.
v6: https://lore.kernel.org/all/[email protected]
- Improve test code.
- Change infinite for loop to for_each_clear_bit_from.
v5: https://lore.kernel.org/all/[email protected]
- Improve test code.
- Change the "goto again" code structure to a for loop.
v4: https://lore.kernel.org/all/[email protected]
- Test code has been added to PATCH v2.
v3: https://lore.kernel.org/all/[email protected]
- Code optimization was performed on PATCH v1.
v2: https://lore.kernel.org/all/[email protected]
- Do not introduce find_last_bit_from().
v1: https://lore.kernel.org/all/[email protected]
Yi Sun (2):
lib: bitmap: add tests for bitmap_find_next_zero_area_off()
lib: bitmap: optimize bitmap_find_next_zero_area_off()
lib/bitmap.c | 31 ++++++++++++++++--------------- lib/find_bit_benchmark.c | 17 +++++++++++++++++ lib/test_bitmap.c | 38 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 71 insertions(+), 15 deletions(-)
Signature · 1 line
2.34.1