[lldb/Disassembler] Move address resolution into the ParseInstructions function
authorPavel Labath <pavel@labath.sk>
Thu, 5 Mar 2020 12:48:56 +0000 (13:48 +0100)
committerPavel Labath <pavel@labath.sk>
Fri, 6 Mar 2020 10:23:41 +0000 (11:23 +0100)
commit92c0cda92847053297ad1f083f13469ff7b43871
tree4624be22ec9381a7dc2aca1a51cd14b3240ff5cc
parent8e4a8677be3061317056335d298d85ce60c23dff
[lldb/Disassembler] Move address resolution into the ParseInstructions function

The static Disassembler can be thought of as shorthands for three
operations:
- fetch an appropriate disassembler instance (FindPluginForTarget)
- ask it to dissassemble some bytes (ParseInstructions)
- ask it to dump the disassembled instructions (PrintInstructions)

The only thing that's standing in the way of this interpretation is that
the Disassemble function also does some address resolution before
calling ParseInstructions. This patch moves this functionality into
ParseInstructions so that it is available to users who call
ParseInstructions directly.
lldb/include/lldb/Core/Disassembler.h
lldb/source/Core/Disassembler.cpp