summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h
diff options
context:
space:
mode:
authorJohnny Chen <johnny.chen@apple.com>2012-03-02 21:32:50 +0000
committerJohnny Chen <johnny.chen@apple.com>2012-03-02 21:32:50 +0000
commit213ba7c7c36e6e970f5bd243e888c13f6880c739 (patch)
tree30c949d01a99bd80972e897ff8beedffd8190499 /lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h
parentaa1f96add58c968e6693f63bb8ab0df06d175e07 (diff)
downloadbcm5719-llvm-213ba7c7c36e6e970f5bd243e888c13f6880c739.tar.gz
bcm5719-llvm-213ba7c7c36e6e970f5bd243e888c13f6880c739.zip
rdar://problem/10652076
Add logic to GDBRemoteRegisterContext class to be able to read/write a "composite" register which has "primordial" registers as its constituents. In particular, Read/WriteRegisterBytes() now delegate to Get/SetPrimordialRegister() helper methods to read/write register contents. Also modify RegisterValue class to be able to parse "register write" string value for the NEON quadword registers which is displayed as a vector of uint8's. Example: (lldb) register write q0 "{0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 0x09 0x0a 0x0b 0x0c 0x0d 0x0e 0x0f 0x10}" (lldb) register read q0 q0 = {0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08 0x09 0x0a 0x0b 0x0c 0x0d 0x0e 0x0f 0x10} (lldb) register read --format uint8_t[] s0 s0 = {0x01 0x02 0x03 0x04} (lldb) register read --format uint8_t[] d0 d0 = {0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08} (lldb) register read --format uint8_t[] d1 d1 = {0x09 0x0a 0x0b 0x0c 0x0d 0x0e 0x0f 0x10} llvm-svn: 151939
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h
index 9f96e77cb54..257baf4df83 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.h
@@ -21,7 +21,7 @@
#include "lldb/Core/ConstString.h"
#include "lldb/Core/DataExtractor.h"
#include "lldb/Target/RegisterContext.h"
-
+#include "GDBRemoteCommunicationClient.h"
class ThreadGDBRemote;
class ProcessGDBRemote;
@@ -246,6 +246,13 @@ protected:
bool m_read_all_at_once;
private:
+ // Helper function for ReadRegisterBytes().
+ bool GetPrimordialRegister(const lldb_private::RegisterInfo *reg_info,
+ GDBRemoteCommunicationClient &gdb_comm);
+ // Helper function for WriteRegisterBytes().
+ bool SetPrimordialRegister(const lldb_private::RegisterInfo *reg_info,
+ GDBRemoteCommunicationClient &gdb_comm);
+
//------------------------------------------------------------------
// For GDBRemoteRegisterContext only
//------------------------------------------------------------------
OpenPOWER on IntegriCloud