diff options
| author | Benjamin Maxwell <benjamin.maxwell@arm.com> | 2025-11-13 08:57:19 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-11-13 08:57:19 +0000 |
| commit | d2a2b169f6cdfc2864f83ebc221dc771a9a1697d (patch) | |
| tree | 3268b9981919451dd09951cf7155775c83a6cc5c /libunwind | |
| parent | f038dfd22d111303d928af4cbcad37498c020c4e (diff) | |
[libunwind] Ensure zaDisable() is called in jumpto/returnto (NFC) (#167674)
This is an NFC for now, as the SME checks for macOS platforms are not
implemented, so zaDisable() is a no-op, but both paths for resuming from
an exception should disable ZA.
This is a fixup for a recent change in #165066.
Diffstat (limited to 'libunwind')
| -rw-r--r-- | libunwind/src/Registers.hpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/libunwind/src/Registers.hpp b/libunwind/src/Registers.hpp index 28649fafb23d..45a2b0921ea3 100644 --- a/libunwind/src/Registers.hpp +++ b/libunwind/src/Registers.hpp @@ -1862,16 +1862,13 @@ public: v128 getVectorRegister(int num) const; void setVectorRegister(int num, v128 value); static const char *getRegisterName(int num); + void jumpto(unsigned walkedFrames = 0) { + zaDisable(); + __libunwind_Registers_arm64_jumpto(this, walkedFrames); + } #ifdef _LIBUNWIND_TRACE_RET_INJECT _LIBUNWIND_TRACE_NO_INLINE - void returnto(unsigned walkedFrames) { - __libunwind_Registers_arm64_jumpto(this, walkedFrames); - } -#else - void jumpto() { - zaDisable(); - __libunwind_Registers_arm64_jumpto(this, 0); - } + void returnto(unsigned walkedFrames) { jumpto(walkedFrames); } #endif static constexpr int lastDwarfRegNum() { return _LIBUNWIND_HIGHEST_DWARF_REGISTER_ARM64; |
