[Lldb-commits] [PATCH] D24124: [LLDB][MIPS] Fix register read/write for 32 bit big endian system
Nitesh Jain via lldb-commits
lldb-commits at lists.llvm.org
Wed Sep 21 04:44:37 PDT 2016
nitesh.jain updated the summary for this revision.
nitesh.jain updated this revision to Diff 72024.
https://reviews.llvm.org/D24124
Files:
source/Core/RegisterValue.cpp
source/Plugins/Process/Linux/NativeRegisterContextLinux.cpp
Index: source/Plugins/Process/Linux/NativeRegisterContextLinux.cpp
===================================================================
--- source/Plugins/Process/Linux/NativeRegisterContextLinux.cpp
+++ source/Plugins/Process/Linux/NativeRegisterContextLinux.cpp
@@ -169,7 +169,7 @@
if (error.Success())
// First cast to an unsigned of the same size to avoid sign extension.
- value.SetUInt64(static_cast<unsigned long>(data));
+ value.SetUInt(static_cast<unsigned long>(data), size);
if (log)
log->Printf("NativeRegisterContextLinux::%s() reg %s: 0x%lx", __FUNCTION__,
Index: source/Core/RegisterValue.cpp
===================================================================
--- source/Core/RegisterValue.cpp
+++ source/Core/RegisterValue.cpp
@@ -633,8 +633,11 @@
default:
break;
case 1:
+ return *(const uint8_t *)buffer.bytes;
case 2:
+ return *(const uint16_t *)buffer.bytes;
case 4:
+ return *(const uint32_t *)buffer.bytes;
case 8:
return *(const uint64_t *)buffer.bytes;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D24124.72024.patch
Type: text/x-patch
Size: 1064 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20160921/56362383/attachment.bin>
More information about the lldb-commits
mailing list