Re: [PATCH v2] binfmt_elf: Align eligible read-only PT_LOAD segments to PMD_SIZE for THP
From: hev
Date: Sun Mar 08 2026 - 05:57:51 EST
Hi,
I ran a quick benchmark on x86_64 as well.
Machine: AMD Ryzen 9 7950X
Binutils: 2.46
GCC: 15.2.1 (built with -z,noseparate-code + --enable-host-pie)
Workload: building Linux v7.0-rc1 with x86_64_defconfig.
Without patch:
* instructions: 8,246,133,611,932
* cpu-cycles: 8,001,028,142,928
* itlb-misses: 3,672,158,331
* time elapsed: 64.66 s
With patch:
* instructions: 8,246,025,137,750
* cpu-cycles: 7,565,925,107,502
* itlb-misses: 26,821,242
* time elapsed: 61.97 s
Instructions are basically unchanged. iTLB misses drop from ~3.67B to
~26M (~99.27% reduction), which results in about a ~5.44% reduction in
cycles and ~4.18% shorter wall time for this workload.
Thanks,
Rui