[Lldb-commits] [PATCH] D96463: [LLDB] Arm64/Linux test case for MTE and Pointer Authentication regset

David Spickett via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Mar 9 02:18:53 PST 2021


DavidSpickett added inline comments.


================
Comment at: lldb/test/API/commands/register/register/aarch64_dynamic_regset/TestArm64DynamicRegsets.py:96
+            if 'Scalable Vector Extension Registers' in registerSet.GetName():
+                self.assertTrue(self.isAArch64SVE(
+                ), 'LLDB enabled AArch64 SVE register set when it was disabled by target.')
----------------
Move the closing `)` onto the first line. Also I'd indent the line below like:
```
self.assertTrue(self.isAArch64SVE(), 
    'LLDB enabled AArch64 SVE register set when it was disabled by target.')
self.....
```

(applies to the next two as well)


================
Comment at: lldb/test/API/commands/register/register/aarch64_dynamic_regset/TestArm64DynamicRegsets.py:106
+            if 'Pointer Authentication Registers' in registerSet.GetName():
+                self.assertTrue(self.isAArch64MTE(
+                ), 'LLDB enabled AArch64 Pointer Authentication register set when it was disabled by target.')
----------------
Should be `isAArch64PAuth`


================
Comment at: lldb/test/API/commands/register/register/aarch64_dynamic_regset/main.c:81-82
+  unsigned int sve_is_enabled = hwcap & HWCAP_SVE;
+  unsigned int pauth_is_enabled = hwcap & HWCAP_PACA;
+  unsigned int mte_is_enabled = hwcap2 & HWCAP2_MTE;
+
----------------
These are unused since we get it from the cpuinfo, then you can inline the sve check in the if below.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D96463/new/

https://reviews.llvm.org/D96463



More information about the lldb-commits mailing list