[PATCH 0/2] uapi: Refactor __GENMASK() and __GENMASK_ULL() for
From: I Hsin Cheng
Date: Tue Feb 11 2025 - 11:24:29 EST
This patch series refactor the implementation of the macros
__GENMASK() and __GENMASK_ULL() in order to speed up the operation by
reducing the number of instructions.
All the changes pass the unit tests and have used bloat-o-meter to test
the size shrink for vmlinux. Performance tests comparison are list in
each patches.
$ ./scripts/bloat-o-meter vmlinux_old vmlinux_new
add/remove: 0/2 grow/shrink: 46/510 up/down: 464/-1733 (-1269)
...
Total: Before=22438085, After=22436816, chg -0.01%
Patch 1:
Refactor __GENMASK()
Patch 2:
Refactor __GENMASK_ULL()
I Hsin Cheng (2):
uapi: Refactor __GENMASK() for speed-up
uapi: Refactor __GENMASK_ULL() for speed-up
include/uapi/linux/bits.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--
2.43.0