[Lldb-commits] [lldb] r157275 - /lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp

Johnny Chen johnny.chen at apple.com
Tue May 22 11:59:38 PDT 2012


Author: johnny
Date: Tue May 22 13:59:38 2012
New Revision: 157275

URL: http://llvm.org/viewvc/llvm-project?rev=157275&view=rev
Log:
The RegisterInfo descriptors for the convenience registers can specify an offset to be added to the offset as derived from
the value_regs field, which is useful for future expansion purposes.  As of now, we have:

    calculated_offset_of_eax = offset_of_rax + (offset_of_eax_from_the_descriptor which is 0)

Modified:
    lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp

Modified: lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp?rev=157275&r1=157274&r2=157275&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp (original)
+++ lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp Tue May 22 13:59:38 2012
@@ -990,7 +990,7 @@
                 {
                     // The name matches the existing primordial entry.
                     // Find and assign the offset, and then add this composite register entry.
-                    g_conv_register_infos[i].byte_offset = reg_info->byte_offset;
+                    g_conv_register_infos[i].byte_offset = reg_info->byte_offset + g_conv_register_infos[i].byte_offset;
                     // Update the value_regs and the kinds fields in order to delegate to the primordial register.
                     g_conv_register_infos[i].value_regs[0] = j;
                     g_conv_register_infos[i].kinds[eRegisterKindLLDB] = ++reg_kind;





More information about the lldb-commits mailing list