summaryrefslogtreecommitdiff
path: root/tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git
diff options
context:
space:
mode:
authorHeiko Carstens <hca@linux.ibm.com>2026-01-13 20:44:00 +0100
committerHeiko Carstens <hca@linux.ibm.com>2026-01-17 15:52:49 +0100
commit48b4790f054994d4df6d1025ec9267b19618f0ec (patch)
tree0333bbd118d452d31e0e833efe9a9d9e9902ff3e /tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git
parent05405b8fd284189278636a0392976cbec3bb6d19 (diff)
s390/preempt: Optimize __preempt_count_dec_and_test()
Provide an inline assembly using alternatives to avoid the need of a base register due to relocatable lowcore when adding or subtracting small constants from preempt_count. Main user is preempt_enable(), which subtracts one from preempt_count and tests if the result is zero. With this the generated code changes from 1000b8: a7 19 00 00 lghi %r1,0 1000bc: eb ff 13 a8 00 6e alsi 936(%r1),-1 1000c2: a7 54 00 05 jnhe 1000cc <__rcu_read_unlock+0x14> to something like this: 1000b8: eb ff 03 a8 00 6e alsi 936,-1 1000be: a7 54 00 05 jnhe 1000c8 <__rcu_read_unlock+0x10> Kernel image size is reduced by 45kb (bloat-o-meter -t, defconfig, gcc15). Reviewed-by: Sven Schnelle <svens@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to 'tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions