1 //===-- ThreadPlanStepOverRange.h -------------------------------*- C++ -*-===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is distributed under the University of Illinois Open Source 6 // License. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 10 #ifndef liblldb_ThreadPlanStepOverRange_h_ 11 #define liblldb_ThreadPlanStepOverRange_h_ 12 13 #include "lldb/Core/AddressRange.h" 14 #include "lldb/Target/StackID.h" 15 #include "lldb/Target/Thread.h" 16 #include "lldb/Target/ThreadPlanStepRange.h" 17 18 namespace lldb_private { 19 20 class ThreadPlanStepOverRange : public ThreadPlanStepRange, 21 ThreadPlanShouldStopHere { 22 public: 23 ThreadPlanStepOverRange(Thread &thread, const AddressRange &range, 24 const SymbolContext &addr_context, 25 lldb::RunMode stop_others, 26 LazyBool step_out_avoids_no_debug); 27 28 ~ThreadPlanStepOverRange() override; 29 30 void GetDescription(Stream *s, lldb::DescriptionLevel level) override; 31 bool ShouldStop(Event *event_ptr) override; 32 33 protected: 34 bool DoPlanExplainsStop(Event *event_ptr) override; 35 bool DoWillResume(lldb::StateType resume_state, bool current_plan) override; 36 SetFlagsToDefault()37 void SetFlagsToDefault() override { 38 GetFlags().Set(ThreadPlanStepOverRange::s_default_flag_values); 39 } 40 41 private: 42 static uint32_t s_default_flag_values; 43 44 void SetupAvoidNoDebug(LazyBool step_out_avoids_code_without_debug_info); 45 bool IsEquivalentContext(const SymbolContext &context); 46 47 bool m_first_resume; 48 49 DISALLOW_COPY_AND_ASSIGN(ThreadPlanStepOverRange); 50 }; 51 52 } // namespace lldb_private 53 54 #endif // liblldb_ThreadPlanStepOverRange_h_ 55