[Lldb-commits] [PATCH] D34929: respect target.x86-disassembly-flavor when using `memory read`
Jeffrey Crowell via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Sat Jul 1 13:11:19 PDT 2017
crowell created this revision.
crowell added a project: LLDB.
in DataDumpExtractor, respect the disassembly flavor, useful for using `x/i (gdb-style)` or `memory read --format instruction`
(lldb) x/i $pc
-> 0x1000013fe: 48 c7 85 50 fb ff ff 00 00 00 00 movq $0x0, -0x4b0(%rbp)
(lldb) settings set target.x86-disassembly-flavor intel
(lldb) x/i $pc
-> 0x1000013fe: 48 c7 85 50 fb ff ff 00 00 00 00 mov qword ptr [rbp - 0x4b0], 0x0
instead of how it was previously
(lldb) x/i $pc
-> 0x1000013fe: 48 c7 85 50 fb ff ff 00 00 00 00 movq $0x0, -0x4b0(%rbp)
(lldb) settings set target.x86-disassembly-flavor intel
(lldb) x/i $pc
-> 0x1000013fe: 48 c7 85 50 fb ff ff 00 00 00 00 movq $0x0, -0x4b0(%rbp)
Repository:
rL LLVM
https://reviews.llvm.org/D34929
Files:
source/Core/DumpDataExtractor.cpp
Index: source/Core/DumpDataExtractor.cpp
===================================================================
--- source/Core/DumpDataExtractor.cpp
+++ source/Core/DumpDataExtractor.cpp
@@ -154,7 +154,8 @@
target_sp = exe_scope->CalculateTarget();
if (target_sp) {
DisassemblerSP disassembler_sp(Disassembler::FindPlugin(
- target_sp->GetArchitecture(), nullptr, nullptr));
+ target_sp->GetArchitecture(),
+ target_sp->GetDisassemblyFlavor(), nullptr));
if (disassembler_sp) {
lldb::addr_t addr = base_addr + start_offset;
lldb_private::Address so_addr;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D34929.105002.patch
Type: text/x-patch
Size: 624 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20170701/384a603c/attachment.bin>
More information about the lldb-commits
mailing list