summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/ThreadPlanStepOut.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/ThreadPlanStepOut.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/ThreadPlanStepOut.cpp')
-rw-r--r--lldb/source/Target/ThreadPlanStepOut.cpp37
1 files changed, 3 insertions, 34 deletions
diff --git a/lldb/source/Target/ThreadPlanStepOut.cpp b/lldb/source/Target/ThreadPlanStepOut.cpp
index 8a3bdd8146c..92403cb92ed 100644
--- a/lldb/source/Target/ThreadPlanStepOut.cpp
+++ b/lldb/source/Target/ThreadPlanStepOut.cpp
@@ -18,7 +18,6 @@
#include "lldb/Core/ValueObjectConstResult.h"
#include "lldb/Symbol/Block.h"
#include "lldb/Symbol/Function.h"
-#include "lldb/Symbol/Symbol.h"
#include "lldb/Symbol/Type.h"
#include "lldb/Target/ABI.h"
#include "lldb/Target/Process.h"
@@ -45,8 +44,7 @@ ThreadPlanStepOut::ThreadPlanStepOut
Vote stop_vote,
Vote run_vote,
uint32_t frame_idx,
- LazyBool step_out_avoids_code_without_debug_info,
- bool continue_to_next_branch
+ LazyBool step_out_avoids_code_without_debug_info
) :
ThreadPlan (ThreadPlan::eKindStepOut, "Step out", thread, stop_vote, run_vote),
ThreadPlanShouldStopHere (this),
@@ -88,8 +86,7 @@ ThreadPlanStepOut::ThreadPlanStepOut
eVoteNoOpinion,
eVoteNoOpinion,
frame_idx - 1,
- eLazyBoolNo,
- continue_to_next_branch));
+ eLazyBoolNo));
static_cast<ThreadPlanStepOut *>(m_step_out_to_inline_plan_sp.get())->SetShouldStopHereCallbacks(nullptr, nullptr);
m_step_out_to_inline_plan_sp->SetPrivate(true);
}
@@ -104,35 +101,7 @@ ThreadPlanStepOut::ThreadPlanStepOut
// Find the return address and set a breakpoint there:
// FIXME - can we do this more securely if we know first_insn?
- Address return_address (return_frame_sp->GetFrameCodeAddress());
- if (continue_to_next_branch)
- {
- SymbolContext return_address_sc;
- AddressRange range;
- Address return_address_decr_pc = return_address;
- if (return_address_decr_pc.GetOffset() > 0)
- return_address_decr_pc.Slide (-1);
-
- return_address_decr_pc.CalculateSymbolContext (&return_address_sc, lldb::eSymbolContextLineEntry | lldb::eSymbolContextFunction | lldb::eSymbolContextSymbol);
- if (return_address_sc.line_entry.IsValid())
- {
- range = return_address_sc.line_entry.GetSameLineContiguousAddressRange();
- }
- else if (return_address_sc.function)
- {
- range = return_address_sc.function->GetAddressRange();
- }
- else if (return_address_sc.symbol && return_address_sc.symbol->GetByteSizeIsValid())
- {
- range.GetBaseAddress() = return_address_sc.symbol->GetAddress();
- range.SetByteSize (return_address_sc.symbol->GetByteSize());
- }
- if (range.GetByteSize() > 0)
- {
- return_address = m_thread.GetProcess()->AdvanceAddressToNextBranchInstruction (return_address, range);
- }
- }
- m_return_addr = return_address.GetLoadAddress(&m_thread.GetProcess()->GetTarget());
+ m_return_addr = return_frame_sp->GetFrameCodeAddress().GetLoadAddress(&m_thread.GetProcess()->GetTarget());
if (m_return_addr == LLDB_INVALID_ADDRESS)
return;
OpenPOWER on IntegriCloud