summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/source/Target/ThreadPlanStepOut.cpp1
-rw-r--r--lldb/source/Target/ThreadPlanStepOverRange.cpp31
2 files changed, 31 insertions, 1 deletions
diff --git a/lldb/source/Target/ThreadPlanStepOut.cpp b/lldb/source/Target/ThreadPlanStepOut.cpp
index 3687f9aca25..9b0e3204008 100644
--- a/lldb/source/Target/ThreadPlanStepOut.cpp
+++ b/lldb/source/Target/ThreadPlanStepOut.cpp
@@ -415,6 +415,7 @@ ThreadPlanStepOut::QueueInlinedStepPlan (bool queue_now)
{
SymbolContext inlined_sc;
inlined_block->CalculateSymbolContext(&inlined_sc);
+ inlined_sc.target_sp = GetTarget().shared_from_this();
RunMode run_mode = m_stop_others ? lldb::eOnlyThisThread : lldb::eAllThreads;
ThreadPlanStepOverRange *step_through_inline_plan_ptr = new ThreadPlanStepOverRange(m_thread,
inline_range,
diff --git a/lldb/source/Target/ThreadPlanStepOverRange.cpp b/lldb/source/Target/ThreadPlanStepOverRange.cpp
index 44cd14e8b00..08d9e4c7210 100644
--- a/lldb/source/Target/ThreadPlanStepOverRange.cpp
+++ b/lldb/source/Target/ThreadPlanStepOverRange.cpp
@@ -110,7 +110,36 @@ ThreadPlanStepOverRange::ShouldStop (Event *event_ptr)
if (older_frame_sp)
{
const SymbolContext &older_context = older_frame_sp->GetSymbolContext(eSymbolContextEverything);
- if (older_context == m_addr_context)
+
+ // Match as much as is specified in the m_addr_context:
+ // This is a fairly loose sanity check. Note, sometimes the target doesn't get filled
+ // in so I left out the target check. And sometimes the module comes in as the .o file from the
+ // inlined range, so I left that out too...
+
+ bool older_ctx_is_equivalent = false;
+ if (m_addr_context.comp_unit)
+ {
+ if (m_addr_context.comp_unit == older_context.comp_unit)
+ {
+ if (m_addr_context.function && m_addr_context.function == older_context.function)
+ {
+ if (m_addr_context.block && m_addr_context.block == older_context.block)
+ {
+ older_ctx_is_equivalent = true;
+ if (m_addr_context.line_entry.IsValid() && LineEntry::Compare(m_addr_context.line_entry, older_context.line_entry) != 0)
+ {
+ older_ctx_is_equivalent = false;
+ }
+ }
+ }
+ }
+ }
+ else if (m_addr_context.symbol && m_addr_context.symbol == older_context.symbol)
+ {
+ older_ctx_is_equivalent = true;
+ }
+
+ if (older_ctx_is_equivalent)
{
new_plan = m_thread.QueueThreadPlanForStepOut (false,
NULL,
OpenPOWER on IntegriCloud