diff options
| author | Linus Walleij <linusw@kernel.org> | 2026-09-16 12:03:56 +0200 |
|---|---|---|
| committer | Catalin Marinas <catalin.marinas@arm.com> | 2026-10-13 14:05:30 +0100 |
| commit | 7fa0d9b2ec070d9555801fecc5d30953a256122c (patch) | |
| tree | 28188da997d65d4867df2b1be1359df652c87a32 /tools/lib/python/kdoc/python_version.py | |
| parent | d6ae12c900f28d5ae79599947c77b2079e1f55ae (diff) | |
arm64: clear_page[s] using memset
There is no need to try to second-guess the compiler when
clearing memory. Just call memset() like everyone else.
Since memset() already has an architecture-local MOPS
optimization, we do not need to do anything else to preserve
the MOPS optimization.
While at it, implement the shorthand for directly calling
the new prototype clear_pages() for larger page chunks.
No performance regressions can be seen, the fastpath
benchmarks differences are in the noise.
Usama Anjum tested next-20260821 with one warm-up and three repeats
in four sessions, for a total of 12 measured runs. The commands were:
perf bench mem memset -k 1GB -f default -s 16GB
perf bench mem mmap -p 1GB -f demand -s 32GB -l 5
perf bench mem mmap -p 4KB -f demand -s 32GB -l 5
The results were:
aws-m7g.metal:
Benchmark Base bytes/sec Change with patch
memset 1GB 63932542232.12 1.92%
mmap 1GB 63272579168.03 -0.57%
mmap 4KB 49692830849.48 -1.11%
cesw-aarch64-ampereone-1s-a192-32x:
Benchmark Base bytes/sec Change with patch
memset 1GB 33895562998.71 0.25%
mmap 1GB 34338454210.17 1.16%
mmap 4KB 25687107580.90 -0.85%
Assisted-by: LLM
Suggested-by: Will Deacon <will@kernel.org>
Tested-by: Usama Anjum <usama.anjum@arm.com>
Link: https://lore.kernel.org/linux-arm-kernel/20260303-aarch64-clear-pages-v1-1-ad0c3ee9a555@kernel.org/
Link: https://lore.kernel.org/linux-arm-kernel/67ab6c51-4511-46ab-931b-a4323551147a@arm.com/
Signed-off-by: Linus Walleij <linusw@kernel.org>
Reviewed-by: Leonardo Bras <leo.bras@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'tools/lib/python/kdoc/python_version.py')
0 files changed, 0 insertions, 0 deletions
