[Lldb-commits] [PATCH] D15533: Make the aarch64 lldb-server capable of debugging arm32 applications

Oleksiy Vyalov via lldb-commits lldb-commits at lists.llvm.org
Tue Dec 15 14:10:40 PST 2015


ovyalov accepted this revision.
This revision is now accepted and ready to land.

================
Comment at: source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp:973
@@ +972,3 @@
+{
+    // PTRACE_PEEKUSER don't work in the aarch64 liux kernel used on android devices (always return
+    // "Bad address"). To avoid using PTRACE_PEEKUSER we read out the full GPR register set instead.
----------------
s/liux/linux

================
Comment at: source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp:1016
@@ +1015,3 @@
+#else // __aarch64__
+    int regset = NT_PRSTATUS;
+    struct iovec ioVec;
----------------
Could you wrap aarch64 code into a static function in NativeRegisterContextLinux_arm64 so it can be reused both here and in NativeRegisterContextLinux_arm64::DoReadGPR?

================
Comment at: source/Plugins/Process/Linux/NativeRegisterContextLinux_arm.cpp:1018
@@ +1017,3 @@
+    struct iovec ioVec;
+    Error error;
+
----------------
It seems, error isn't used.

================
Comment at: source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp:153
@@ +152,3 @@
+        default:
+            return nullptr;
+    }
----------------
Please add logging here including target_arch.GetMachine() value.


http://reviews.llvm.org/D15533





More information about the lldb-commits mailing list