summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/Process.cpp
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2016-01-08 02:26:03 +0000
committerJason Molenda <jmolenda@apple.com>2016-01-08 02:26:03 +0000
commit7cb9d98cf9df2d6544cad826ce9e3719c406f0cf (patch)
tree1b31911e0a54de0ae976d90bc8d11dadeebad4a0 /lldb/source/Target/Process.cpp
parentbfcff3856a5590d3187999e6c6c08057ef36e261 (diff)
downloadbcm5719-llvm-7cb9d98cf9df2d6544cad826ce9e3719c406f0cf.tar.gz
bcm5719-llvm-7cb9d98cf9df2d6544cad826ce9e3719c406f0cf.zip
Revert r257117 "Performance improvement: Change lldb so that it
puts a breakpoint" it is causing a regression in the TestStepNoDebug test case on ubuntu 14.04 with gcc 4.9.2. Thanks for the email Siva. I'll recommit when I've figured out the regression. llvm-svn: 257138
Diffstat (limited to 'lldb/source/Target/Process.cpp')
-rw-r--r--lldb/source/Target/Process.cpp62
1 files changed, 0 insertions, 62 deletions
diff --git a/lldb/source/Target/Process.cpp b/lldb/source/Target/Process.cpp
index e4fe419660e..311c695860f 100644
--- a/lldb/source/Target/Process.cpp
+++ b/lldb/source/Target/Process.cpp
@@ -6515,65 +6515,3 @@ Process::ResetImageToken(size_t token)
if (token < m_image_tokens.size())
m_image_tokens[token] = LLDB_INVALID_IMAGE_TOKEN;
}
-
-Address
-Process::AdvanceAddressToNextBranchInstruction (Address default_stop_addr, AddressRange range_bounds)
-{
- Target &target = GetTarget();
- DisassemblerSP disassembler_sp;
- InstructionList *insn_list = NULL;
-
- Address retval = default_stop_addr;
-
- if (target.GetUseFastStepping() == false)
- return retval;
- if (default_stop_addr.IsValid() == false)
- return retval;
-
- ExecutionContext exe_ctx (this);
- const char *plugin_name = nullptr;
- const char *flavor = nullptr;
- const bool prefer_file_cache = true;
- disassembler_sp = Disassembler::DisassembleRange(target.GetArchitecture(),
- plugin_name,
- flavor,
- exe_ctx,
- range_bounds,
- prefer_file_cache);
- if (disassembler_sp.get())
- insn_list = &disassembler_sp->GetInstructionList();
-
- if (insn_list == NULL)
- {
- return retval;
- }
-
- size_t insn_offset = insn_list->GetIndexOfInstructionAtAddress (default_stop_addr);
- if (insn_offset == UINT32_MAX)
- {
- return retval;
- }
-
- uint32_t branch_index = insn_list->GetIndexOfNextBranchInstruction (insn_offset, target);
- if (branch_index == UINT32_MAX)
- {
- return retval;
- }
-
- if (branch_index > insn_offset)
- {
- Address next_branch_insn_address = insn_list->GetInstructionAtIndex (branch_index)->GetAddress();
- if (next_branch_insn_address.IsValid() && range_bounds.ContainsFileAddress (next_branch_insn_address))
- {
- retval = next_branch_insn_address;
- }
- }
-
- if (disassembler_sp.get())
- {
- // FIXME: The DisassemblerLLVMC has a reference cycle and won't go away if it has any active instructions.
- disassembler_sp->GetInstructionList().Clear();
- }
-
- return retval;
-}
OpenPOWER on IntegriCloud