28 size_t num_addresses,
bool stop_others,
35 m_should_stop(false), m_ran_analyze(false), m_explains_stop(false),
36 m_until_points(), m_stop_others(stop_others) {
48 if (return_frame_sp) {
52 target_sp->CreateBreakpoint(
m_return_addr,
true,
false).get();
54 if (return_bp !=
nullptr) {
66 for (
size_t i = 0; i < num_addresses; i++) {
68 target_sp->CreateBreakpoint(address_list[i],
true,
false).get();
69 if (until_bp !=
nullptr) {
102 s->
Printf(
" - stepped out");
105 s->
Printf(
"Stepping from address 0x%" PRIx64
" until we reach 0x%" PRIx64
106 " using breakpoint %d",
112 s->
Printf(
"Stepping from address 0x%" PRIx64
" until we reach one of:",
115 s->
Printf(
"\n\t0x%" PRIx64
" (bp: %d)", (uint64_t)(*pos).first,
119 s->
Printf(
" stepped out address is 0x%" PRIx64
".",
128 "Could not create hardware breakpoint for thread plan.");
132 error->PutCString(
"Could not create return breakpoint.");
153 StopReason reason = stop_info_sp->GetStopReason();
185 if (this_site->GetNumberOfConstituents() == 1)
194 if (this_site->IsBreakpointAtThisSite((*pos).second)) {
210 if (older_frame_sp) {
212 older_frame_sp->GetSymbolContext(eSymbolContextEverything);
217 done = (older_context == stack_context);
231 if (this_site->GetNumberOfConstituents() == 1)
282 if (return_bp !=
nullptr)
288 if (until_bp !=
nullptr)
302 if (return_bp !=
nullptr)
308 if (until_bp !=
nullptr)
320 LLDB_LOGF(log,
"Completed step until plan.");
static llvm::raw_ostream & error(Stream &strm)
#define LLDB_LOGF(log,...)
General Outline: A breakpoint has four main parts, a filter, a resolver, the list of breakpoint locat...
void SetBreakpointKind(const char *kind)
Set the "kind" description for a breakpoint.
bool HasResolvedLocations() const
Return whether this breakpoint has any resolved locations.
void SetThreadID(lldb::tid_t thread_id)
Set the valid thread to be checked when the breakpoint is hit.
void SetEnabled(bool enable) override
If enable is true, enable the breakpoint, if false disable it.
StopPointSiteList< lldb_private::BreakpointSite > & GetBreakpointSiteList()
SymbolContextScope * GetSymbolContextScope() const
StopPointSiteSP FindByID(typename StopPointSite::SiteID site_id)
Returns a shared pointer to the site with id site_id.
lldb::break_id_t GetID() const
A stream class that can stream formatted output to a file.
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
virtual void CalculateSymbolContext(SymbolContext *sc)=0
Reconstruct the object's symbol context into sc.
Defines a symbol context baton that can be handed other debug core functions.
lldb::BreakpointSP GetBreakpointByID(lldb::break_id_t break_id)
bool RemoveBreakpointByID(lldb::break_id_t break_id)
bool DoWillResume(lldb::StateType resume_state, bool current_plan) override
lldb::addr_t m_step_from_insn
bool MischiefManaged() override
lldb::addr_t m_return_addr
void GetDescription(Stream *s, lldb::DescriptionLevel level) override
Print a description of this thread to the stream s.
bool DoPlanExplainsStop(Event *event_ptr) override
until_collection m_until_points
ThreadPlanStepUntil(Thread &thread, lldb::addr_t *address_list, size_t num_addresses, bool stop_others, uint32_t frame_idx=0)
bool StopOthers() override
~ThreadPlanStepUntil() override
bool ValidatePlan(Stream *error) override
Returns whether this plan could be successfully created.
lldb::StateType GetPlanRunState() override
bool ShouldStop(Event *event_ptr) override
lldb::break_id_t m_return_bp_id
bool IsUsuallyUnexplainedStopReason(lldb::StopReason)
void SetPlanComplete(bool success=true)
Thread & GetThread()
Returns the Thread that is using this thread plan.
virtual bool MischiefManaged()
bool m_could_not_resolve_hw_bp
lldb::StopInfoSP GetPrivateStopInfo()
virtual lldb::StackFrameSP GetStackFrameAtIndex(uint32_t idx)
lldb::TargetSP CalculateTarget() override
#define LLDB_INVALID_BREAK_ID
#define LLDB_BREAK_ID_IS_VALID(bid)
#define LLDB_INVALID_ADDRESS
A class that represents a running process on the host machine.
Log * GetLog(Cat mask)
Retrieve the Log object for the channel associated with the given log enum.
std::shared_ptr< lldb_private::StackFrame > StackFrameSP
std::shared_ptr< lldb_private::BreakpointSite > BreakpointSiteSP
DescriptionLevel
Description levels for "void GetDescription(Stream *, DescriptionLevel)" calls.
StateType
Process and Thread States.
@ eStateRunning
Process or thread is running and can't be examined.
std::shared_ptr< lldb_private::StopInfo > StopInfoSP
StopReason
Thread stop reasons.
std::shared_ptr< lldb_private::Target > TargetSP