selftests/damon: add Python-written DAMON functionality tests
Status from this message: [merged mm-stable] selftests-damon-add-a-test-for-update_schemes_tried_regions-hang-bug.patch removed from -mm tree
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest5 patches 0 repliesApplied 5/5
- v15 patches 1 replySuperseded
Changes in v2 from the cover letter
(https://lore.kernel.org/damon/[email protected]/)
- Fix conflicts on latest mm-unstable tree
Patches in v2 All 5 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | selftests/damon: implement a python module for test-purpose DAMON sysfs controlstools/ | +102 | 0 replies | Applied |
| 2/5 | selftests/damon/_damon_sysfs: implement kdamonds start functiontools/ | +206 | 0 replies | Applied |
| 3/5 | selftests/damon/_damon_sysfs: implement updat_schemes_tried_bytes commandtools/ | +14 | 0 replies | Applied |
| 4/5 | selftests/damon: add a test for update_schemes_tried_regions sysfs commandtools/ tools/ tools/ | +98 | 0 replies | Applied |
| 5/5 | selftests/damon: add a test for update_schemes_tried_regions hang bugtools/ tools/ | +34 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/5] selftests/damon: add Python-written DAMON functionality tests
Changes from v1
(https://lore.kernel.org/damon/[email protected]/)
- Fix conflicts on latest mm-unstable tree
Changes from RFC
(https://lore.kernel.org/damon/[email protected]/)
- Make the working set size estimation test more reliable
- Wordsmith coverletter and commit messages
- Rename _damon.py to _damon_sysfs.py
DAMON exports most of its functionality via its sysfs interface. Hence most DAMON functionality tests could be implemented using the interface. However, because the interfaces require simple but multiple operations for many controls, writing all such tests from the scratch could be repetitive and time consuming.
Implement a minimum DAMON sysfs control module, and a couple of DAMON functionality tests using the control module. The first test is for ensuring minimum accuracy of data access monitoring, and the second test is for finding if a previously found and fixed bug is introduced again.
Note that the DAMON sysfs control module is only for avoiding duplicating code in tests. For convenient and general control of DAMON, users should use DAMON user-space tools that developed for the purpose, such as damo[1].
[1] https://github.com/damonitor/damo
Patches Sequence
----------------
This patchset is constructed with five patches. The first three patches implement a Python-written test implementation-purpose DAMON sysfs control module. The implementation is incrementally done in the sequence of the basic data structure (first patch) first, kdamonds start command (second patch) next, and finally DAMOS tried bytes update command (third patch).
Then two patches for implementing selftests using the module follows. The fourth patch implements a basic functionality test of DAMON for working set estimation accuracy. Finally, the fifth patch implements a corner case test for a previously found bug.
SeongJae Park (5):
selftests/damon: implement a python module for test-purpose DAMON
sysfs controls
selftests/damon/_damon_sysfs: implement kdamonds start function selftests/damon/_damon_sysfs: implement updat_schemes_tried_bytes
command
selftests/damon: add a test for update_schemes_tried_regions sysfs
command
selftests/damon: add a test for update_schemes_tried_regions hang bug
tools/testing/selftests/damon/Makefile | 3 + tools/testing/selftests/damon/_damon_sysfs.py | 322 ++++++++++++++++++ tools/testing/selftests/damon/access_memory.c | 41 +++ ...sysfs_update_schemes_tried_regions_hang.py | 33 ++ ...te_schemes_tried_regions_wss_estimation.py | 55 +++ 5 files changed, 454 insertions(+) create mode 100644 tools/testing/selftests/damon/_damon_sysfs.py create mode 100644 tools/testing/selftests/damon/access_memory.c create mode 100755 tools/testing/selftests/damon/sysfs_update_schemes_tried_regions_hang.py create mode 100755 tools/testing/selftests/damon/sysfs_update_schemes_tried_regions_wss_estimation.py
base-commit: 091b8c820de390a6235595bdb281edab63b9befe
Signature · 1 line
2.34.1