ThreadPlanStepThrough.h revision 038fa8e30621e0e55faed3479387d811986f28b7
1//===-- ThreadPlanStepThrough.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_ThreadPlanStepThrough_h_ 11#define liblldb_ThreadPlanStepThrough_h_ 12 13// C Includes 14// C++ Includes 15// Other libraries and framework includes 16// Project includes 17#include "lldb/Target/Thread.h" 18#include "lldb/Target/ThreadPlan.h" 19 20namespace lldb_private { 21 22class ThreadPlanStepThrough : public ThreadPlan 23{ 24public: 25 virtual ~ThreadPlanStepThrough (); 26 27 virtual void GetDescription (Stream *s, lldb::DescriptionLevel level); 28 virtual bool ValidatePlan (Stream *error); 29 virtual bool PlanExplainsStop (); 30 virtual bool ShouldStop (Event *event_ptr); 31 virtual bool StopOthers (); 32 virtual lldb::StateType GetPlanRunState (); 33 virtual bool WillResume (lldb::StateType resume_state, bool current_plan); 34 virtual bool WillStop (); 35 virtual bool MischiefManaged (); 36 virtual void DidPush(); 37 38protected: 39 ThreadPlanStepThrough (Thread &thread, 40 StackID &return_stack_id, 41 bool stop_others); 42 43 void 44 LookForPlanToStepThroughFromCurrentPC (); 45 46 bool 47 HitOurBackstopBreakpoint(); 48 49private: 50 friend ThreadPlan * 51 Thread::QueueThreadPlanForStepThrough (StackID &return_stack_id, 52 bool abort_other_plans, 53 bool stop_others); 54 55 void ClearBackstopBreakpoint(); 56 57 lldb::ThreadPlanSP m_sub_plan_sp; 58 lldb::addr_t m_start_address; 59 lldb::break_id_t m_backstop_bkpt_id; 60 lldb::addr_t m_backstop_addr; 61 StackID m_return_stack_id; 62 bool m_stop_others; 63 64 DISALLOW_COPY_AND_ASSIGN (ThreadPlanStepThrough); 65 66}; 67 68} // namespace lldb_private 69 70#endif // liblldb_ThreadPlanStepThrough_h_ 71