Landing: 844eae976646
Project / Subsystem
binutils / aarch64
Date
2026-09-09
Author
Sivan Shani <sivsha@sourceware.org>
Commit
844eae9766463cfbd9574ff350334f1e46f43978
Source
public_inbox
Perf win
Yes
Breaking
No
All attributes
- project
- binutils
- subsystem
- aarch64
- patch_id
- —
- commit_hash
- 844eae9766463cfbd9574ff350334f1e46f43978
- source_type
- public_inbox
- headline
- Optimize AArch64 ADD relocations resolving to zero
- tldr
- Optimize AArch64 ADD instructions with zero immediate operands after relocation.
- author
- Sivan Shani <sivsha@sourceware.org>
- outcome
- committed
- performance_win
- true
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • aarch64
- • optimization
- • linker
- • performance
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-09-09T00:00:00.000Z
This commit optimizes AArch64 ADD instructions where the immediate value becomes zero after relocation, as recommended by the ARM architecture specification. It replaces ADD x0, x1, 0 with MOV x0, x1 and ADD x2, x2, 0 with NOP, while handling register 31 (SP) and —no-relax appropriately. This improves code density and performance.