diff options
| author | Uros Bizjak <ubizjak@gmail.com> | 2026-03-30 10:59:22 +0200 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2026-03-31 09:50:10 +0200 |
| commit | 6829f19810e96903d7b532145c3d1701b4d9a0f6 (patch) | |
| tree | e18a4074aefbfc07cd336b25928faf0f326dbd0c /tools/perf/scripts/python/stackcollapse.py | |
| parent | 81310ce4287a23b8ff6e8684de73cfaae88782ca (diff) | |
x86/process/32: Use correct type for 'gs' variable in __show_regs() to avoid zero-extension
Change the type of 'gs' variable in __show_regs() from
'unsigned short' to 'unsigned int'. This prevents unwanted
zero-extension when storing the 16-bit segment register
into a wider general purpose register.
The code improves from:
50: 8c ee mov %gs,%esi
52: 0f b7 f6 movzwl %si,%esi
...
be: 89 74 24 14 mov %esi,0x14(%esp)
to:
50: 8c ef mov %gs,%edi
...
bb: 89 7c 24 14 mov %edi,0x14(%esp)
No functional change intended.
Signed-off-by: Uros Bizjak <ubizjak@gmail.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: https://patch.msgid.link/20260330085938.67985-3-ubizjak@gmail.com
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
