[all-commits] [llvm/llvm-project] 4b99eb: [Sparc] Remove bogus stack adjustment for LD/GD TL...
Jessica Clarke via All-commits
all-commits at lists.llvm.org
Tue Jul 22 08:44:39 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 4b99eb2eb49d8fcdb29ba494501e481cf09831ae
https://github.com/llvm/llvm-project/commit/4b99eb2eb49d8fcdb29ba494501e481cf09831ae
Author: Jessica Clarke <jrtc27 at jrtc27.com>
Date: 2025-07-22 (Tue, 22 Jul 2025)
Changed paths:
M llvm/lib/Target/Sparc/SparcISelLowering.cpp
M llvm/test/CodeGen/SPARC/tls-sp.ll
Log Message:
-----------
[Sparc] Remove bogus stack adjustment for LD/GD TLS (#149890)
This argument is the number of bytes to adjust the stack by for the
duration of the call. In most cases, PEI is able to eliminate the
corresponding call frame pseudos, folding them into the initial stack
frame allocation (rounded up to stack alignment), where it just ends up
allocating more space than needed. However, in the rare case where this
cannot be done, e.g. due to the use of a dynamic alloca, the 1 byte
stack adjustment persists and results in a misaligned stack for the
duration of the call. This has been the case ever since TLS support was
added in cb1dca602c43 ("[Sparc] Add support for TLS in sparc."), and I
can only assume that 1 was used erroneously thinking that it is the
number of arguments (as there is 1 register argument for the call), not
the number of bytes for on-stack arguments.
Fixes: https://github.com/llvm/llvm-project/issues/149808
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list