ScriptedThreadPlan#

class lldb.plugins.scripted_thread_plan.ScriptedThreadPlan(thread_plan: SBThreadPlan)#

Class that provides data for an instance of a LLDB ‘ScriptedThreadPlan’ plug-in class used to construct custom stepping logic.

Methods Summary

explains_stop(event)

Each plan is asked from youngest to oldest if it "explains" the stop.

is_stale()

If your plan is no longer relevant (for instance, you were stepping in a particular stack frame, but some other operation pushed that frame off the stack) return True and your plan will get popped.

should_step()

Whether this thread plan should instruction step one instruction, or continue till the next breakpoint is hit.

should_stop(event)

Whether this thread plan should stop and return control to the user.

stop_description(stream)

Customize the thread plan stop reason when the thread plan is complete.

Methods Documentation

explains_stop(event: SBEvent) bool#

Each plan is asked from youngest to oldest if it “explains” the stop. The first plan to claim the stop wins.

Args:

event (lldb.SBEvent): The process stop event.

Returns:

bool: True if this stop could be claimed by this thread plan, False otherwise. Defaults to True.

is_stale() bool#

If your plan is no longer relevant (for instance, you were stepping in a particular stack frame, but some other operation pushed that frame off the stack) return True and your plan will get popped.

Returns:

bool: True if this thread plan is stale, False otherwise. Defaults to False.

should_step() bool#

Whether this thread plan should instruction step one instruction, or continue till the next breakpoint is hit.

Returns:

bool: True if this plan will instruction step one instruction, False otherwise. Defaults to True.

should_stop(event: SBEvent) bool#

Whether this thread plan should stop and return control to the user. If your plan is done at this point, call SetPlanComplete on your thread plan instance. Also, do any work you need here to set up the next stage of stepping.

Args:

event (lldb.SBEvent): The process stop event.

Returns:

bool: True if this plan wants to stop and return control to the user at this point, False otherwise. Defaults to False.

stop_description(stream: SBStream) None#

Customize the thread plan stop reason when the thread plan is complete.

Args:

stream (lldb.SBStream): The stream containing the stop description.