[Lldb-commits] [lldb] [lldb][AArch64] Add SME2's ZT0 register (PR #70205)

David Spickett via lldb-commits lldb-commits at lists.llvm.org
Thu Oct 26 01:33:46 PDT 2023


================
@@ -625,6 +662,18 @@ NativeRegisterContextLinux_arm64::CacheAllRegisters(uint32_t &cached_size) {
     error = ReadZA();
     if (error.Fail())
       return error;
+
+    // We will only be restoring ZT data if ZA is active. As writing to an
+    // inactive ZT enables ZA, which may not be desireable.
+    if (GetRegisterInfo().IsZTEnabled() &&
+        m_za_header.size > sizeof(m_za_header)) {
----------------
DavidSpickett wrote:

https://github.com/llvm/llvm-project/pull/70303 Addresses the enabled/present thing.

I can't make a `IsZAEnabled` helper until that goes in so whichever one of these lands first I'll sort that out.

For now I'll add some comments to clarify the current code.

https://github.com/llvm/llvm-project/pull/70205


More information about the lldb-commits mailing list