GDB (xrefs)
Loading...
Searching...
No Matches
Classes | Public Member Functions | Public Attributes | Private Attributes | List of all members
thread_info Class Reference

#include "gdbthread.h"

Inheritance diagram for thread_info:

Classes

struct  btrace
 

Public Member Functions

 thread_info (inferior *inf, ptid_t ptid)
 
 ~thread_info ()
 
bool deletable () const
 
void set_running (bool running)
 
const char * name () const
 
void set_name (gdb::unique_xmalloc_ptr< char > name)
 
bool executing () const
 
void set_executing (bool executing)
 
bool resumed () const
 
void set_resumed (bool resumed)
 
void save_suspend_to (thread_suspend_state &suspend) const
 
void restore_suspend_from (const thread_suspend_state &suspend)
 
CORE_ADDR stop_pc () const
 
void set_stop_pc (CORE_ADDR stop_pc)
 
void clear_stop_pc ()
 
bool stop_pc_p () const
 
bool has_pending_waitstatus () const
 
const target_waitstatuspending_waitstatus () const
 
void set_pending_waitstatus (const target_waitstatus &ws)
 
void clear_pending_waitstatus ()
 
gdb_signal stop_signal () const
 
void set_stop_signal (gdb_signal sig)
 
target_stop_reason stop_reason () const
 
void set_stop_reason (target_stop_reason reason)
 
struct thread_fsmthread_fsm () const
 
std::unique_ptr< struct thread_fsmrelease_thread_fsm ()
 
void set_thread_fsm (std::unique_ptr< struct thread_fsm > fsm)
 

Public Attributes

ptid_t ptid
 
int global_num
 
int per_inf_num
 
struct inferiorinf
 
enum thread_state state = THREAD_STOPPED
 
thread_control_state control
 
int current_line = 0
 
struct symtabcurrent_symtab = NULL
 
CORE_ADDR prev_pc = 0
 
int stepped_breakpoint = 0
 
int stepping_over_breakpoint = 0
 
int stepping_over_watchpoint = 0
 
int step_after_step_resume_breakpoint = 0
 
struct target_waitstatus pending_follow
 
int stop_requested = 0
 
struct frame_id initiating_frame = null_frame_id
 
private_thread_info_up priv
 
bool stack_temporaries_enabled = false
 
std::vector< struct value * > stack_temporaries
 
intrusive_list_node< thread_infostep_over_list_node
 
intrusive_list_node< thread_inforesumed_with_pending_wait_status_node
 
displaced_step_thread_state displaced_step_state
 

Private Attributes

bool m_resumed = false
 
bool m_executing = false
 
thread_suspend_state m_suspend
 
gdb::unique_xmalloc_ptr< char > m_name
 
std::unique_ptr< struct thread_fsmm_thread_fsm
 

Detailed Description

Definition at line 247 of file gdbthread.h.

Constructor & Destructor Documentation

◆ thread_info()

thread_info::thread_info ( inferior * inf,
ptid_t ptid )
explicit

◆ ~thread_info()

thread_info::~thread_info ( )

Definition at line 357 of file thread.c.

References ptid, threads_debug_printf, and ~thread_info().

Referenced by ~thread_info().

Member Function Documentation

◆ clear_pending_waitstatus()

void thread_info::clear_pending_waitstatus ( )

◆ clear_stop_pc()

void thread_info::clear_stop_pc ( )
inline

Definition at line 379 of file gdbthread.h.

References m_suspend, and thread_suspend_state::stop_pc.

Referenced by post_create_inferior(), and set_executing().

◆ deletable()

bool thread_info::deletable ( ) const

Definition at line 365 of file thread.c.

References deletable(), and is_current_thread().

Referenced by inferior::clear_thread_list(), deletable(), and delete_thread_1().

◆ executing()

bool thread_info::executing ( ) const
inline

◆ has_pending_waitstatus()

bool thread_info::has_pending_waitstatus ( ) const
inline

◆ name()

const char * thread_info::name ( ) const
inline

◆ pending_waitstatus()

const target_waitstatus & thread_info::pending_waitstatus ( ) const
inline

◆ release_thread_fsm()

std::unique_ptr< struct thread_fsm > thread_info::release_thread_fsm ( )
inline

Definition at line 461 of file gdbthread.h.

References m_thread_fsm.

Referenced by clear_proceed_status_thread(), follow_fork(), and thread_cancel_execution_command().

◆ restore_suspend_from()

void thread_info::restore_suspend_from ( const thread_suspend_state & suspend)
inline

Definition at line 354 of file gdbthread.h.

References m_suspend.

Referenced by infcall_suspend_state::restore().

◆ resumed()

bool thread_info::resumed ( ) const
inline

◆ save_suspend_to()

void thread_info::save_suspend_to ( thread_suspend_state & suspend) const
inline

Definition at line 347 of file gdbthread.h.

References m_suspend.

Referenced by infcall_suspend_state::infcall_suspend_state().

◆ set_executing()

void thread_info::set_executing ( bool executing)

Definition at line 375 of file thread.c.

References clear_stop_pc(), m_executing, and set_executing().

Referenced by handle_one(), and set_executing().

◆ set_name()

void thread_info::set_name ( gdb::unique_xmalloc_ptr< char > name)
inline

Definition at line 314 of file gdbthread.h.

References m_name, and name.

Referenced by thpy_set_name().

◆ set_pending_waitstatus()

void thread_info::set_pending_waitstatus ( const target_waitstatus & ws)

◆ set_resumed()

void thread_info::set_resumed ( bool resumed)

◆ set_running()

void thread_info::set_running ( bool running)

◆ set_stop_pc()

void thread_info::set_stop_pc ( CORE_ADDR stop_pc)
inline

◆ set_stop_reason()

void thread_info::set_stop_reason ( target_stop_reason reason)
inline

◆ set_stop_signal()

void thread_info::set_stop_signal ( gdb_signal sig)
inline

◆ set_thread_fsm()

void thread_info::set_thread_fsm ( std::unique_ptr< struct thread_fsm > fsm)
inline

Definition at line 470 of file gdbthread.h.

References m_thread_fsm.

Referenced by finish_command(), follow_fork(), step_1(), until_break_command(), and until_next_command().

◆ stop_pc()

CORE_ADDR thread_info::stop_pc ( ) const
inline

◆ stop_pc_p()

bool thread_info::stop_pc_p ( ) const
inline

Definition at line 387 of file gdbthread.h.

References m_suspend, and thread_suspend_state::stop_pc.

Referenced by proceed().

◆ stop_reason()

target_stop_reason thread_info::stop_reason ( ) const
inline

Definition at line 438 of file gdbthread.h.

References m_suspend, and thread_suspend_state::stop_reason.

Referenced by clear_proceed_status_thread(), and do_target_wait_1().

◆ stop_signal()

gdb_signal thread_info::stop_signal ( ) const
inline

◆ thread_fsm()

struct thread_fsm * thread_info::thread_fsm ( ) const
inline

Member Data Documentation

◆ control

thread_control_state thread_info::control

Definition at line 343 of file gdbthread.h.

Referenced by remote_target::append_resumption(), arm_linux_copy_svc(), bpstat_clear_actions(), bpstat_do_actions(), bpstat_remove_breakpoint_callback(), breakpoint_about_to_proceed(), clear_proceed_status_thread(), clear_thread_inferior_resources(), continue_command(), currently_stepping(), delete_exception_resume_breakpoint(), delete_single_step_breakpoints(), delete_step_resume_breakpoint(), displaced_step_prepare_throw(), end_stepping_range(), finish_backward(), finish_command(), finish_forward(), finish_step_over(), follow_exec(), follow_fork(), follow_inferior_reset_breakpoints(), handle_inferior_event(), handle_one(), handle_signal_stop(), handle_step_into_function(), handle_step_into_function_backward(), handle_syscall_event(), info_program_command(), inline_frame_is_marked_for_skip(), insert_exception_resume_breakpoint(), insert_exception_resume_from_probe(), insert_longjmp_resume_breakpoint(), insert_single_step_breakpoint(), insert_step_resume_breakpoint_at_sal_1(), keep_going(), keep_going_pass_signal(), keep_going_stepped_thread(), mi_interp::on_about_to_proceed(), mi_interp::on_target_resumed(), pc_in_thread_step_range(), prepare_one_step(), print_stop_location(), proceed(), process_event_stop_test(), record_btrace_start_replaying(), restore_infcall_control_state(), resume_1(), save_infcall_control_state(), schedlock_applies(), set_step_frame(), set_step_info(), should_print_stop_to_console(), until_break_fsm::should_stop(), step_command_fsm::should_stop(), until_next_fsm::should_stop(), finish_command_fsm::should_stop(), step_command_fsm_prepare(), switch_back_to_stepped_thread(), thread_has_single_step_breakpoint_here(), thread_has_single_step_breakpoints_set(), and until_next_command().

◆ current_line

int thread_info::current_line = 0

Definition at line 476 of file gdbthread.h.

Referenced by follow_fork(), process_event_stop_test(), and set_step_info().

◆ current_symtab

struct symtab* thread_info::current_symtab = NULL

Definition at line 477 of file gdbthread.h.

Referenced by follow_fork(), process_event_stop_test(), and set_step_info().

◆ displaced_step_state

displaced_step_thread_state thread_info::displaced_step_state

◆ global_num

int thread_info::global_num

◆ inf

struct inferior* thread_info::inf

Definition at line 301 of file gdbthread.h.

Referenced by ada_get_task_number(), annotate_thread_exited(), attach_post_wait(), bpstat_check_breakpoint_conditions(), child_interrupt(), clear_inline_frame_state(), create_thread_object(), delete_thread_1(), delete_thread_object(), displaced_step_finish(), displaced_step_prepare(), displaced_step_prepare_throw(), do_target_resume(), displaced_step_buffers::finish(), follow_fork(), get_ps_regcache(), get_thread_regcache(), handle_inferior_event(), handle_one(), handle_vfork_done(), internal_resume_ptid(), linux_displaced_step_finish(), linux_displaced_step_prepare(), mi_interp::on_new_thread(), mi_interp::on_thread_exited(), ppc_displaced_step_finish(), ppc_displaced_step_prepare(), ppc_linux_displaced_step_prepare(), displaced_step_buffers::prepare(), prepare_for_detach(), prepare_one_step(), print_full_thread_id(), proceed_resume_thread_checked(), proceed_thread_callback(), remote_target::process_initial_stop_replies(), ps_get_thread_area(), ps_pglobal_lookup(), ps_xfer_memory(), process_stratum_target::random_resumed_with_pending_wait_status(), record_btrace_on_new_thread(), record_btrace_replay_at_breakpoint(), registers_changed_thread(), resume_1(), set_last_target_status_stopped(), set_thread_exited(), should_print_thread(), switch_to_thread_if_alive(), switch_to_thread_no_regs(), thread_alive(), thread_db_find_new_threads_2(), thread_from_lwp(), thread_name(), thread_to_thread_object(), thread_db_target::update_thread_list(), and use_displaced_stepping().

◆ initiating_frame

struct frame_id thread_info::initiating_frame = null_frame_id

◆ m_executing

bool thread_info::m_executing = false
private

Definition at line 568 of file gdbthread.h.

Referenced by executing(), and set_executing().

◆ m_name

gdb::unique_xmalloc_ptr<char> thread_info::m_name
private

Definition at line 577 of file gdbthread.h.

Referenced by name(), and set_name().

◆ m_resumed

bool thread_info::m_resumed = false
private

Definition at line 562 of file gdbthread.h.

Referenced by resumed(), and set_resumed().

◆ m_suspend

thread_suspend_state thread_info::m_suspend
private

◆ m_thread_fsm

std::unique_ptr<struct thread_fsm> thread_info::m_thread_fsm
private

Definition at line 582 of file gdbthread.h.

Referenced by release_thread_fsm(), set_thread_fsm(), and thread_fsm().

◆ pending_follow

struct target_waitstatus thread_info::pending_follow

◆ per_inf_num

int thread_info::per_inf_num

◆ prev_pc

CORE_ADDR thread_info::prev_pc = 0

◆ priv

private_thread_info_up thread_info::priv

◆ ptid

ptid_t thread_info::ptid

Definition at line 259 of file gdbthread.h.

Referenced by ada_get_task_number(), inf_ptrace_target::attach(), bpstat_check_breakpoint_conditions(), btrace_clear(), btrace_disable(), btrace_enable(), btrace_fetch(), btrace_teardown(), clear_inline_frame_state(), clear_proceed_status_thread(), inferior::clear_thread_list(), collect_cores(), delete_thread_1(), displaced_step_prepare_throw(), do_target_wait_1(), elf_none_make_corefile_notes(), ravenscar_thread_target::enable_btrace(), remote_target::enable_btrace(), x86_linux_nat_target::enable_btrace(), aix_thread_target::extra_thread_info(), remote_target::extra_thread_info(), amd_dbgapi_target::extra_thread_info(), fbsd_core_thread_name(), fbsd_make_corefile_notes(), find_thread_of_process(), displaced_step_buffers::finish(), finish_step_over(), follow_fork_inferior(), fprint_dummy_frames(), gcmp(), gdbpy_current_recording(), sol_thread_target::get_ada_task_ptid(), get_thread_regcache(), global_thread_step_over_chain_enqueue(), global_thread_step_over_chain_remove(), handle_one(), info_program_command(), record_btrace_target::info_record(), internal_resume_ptid(), interrupt_thread_callback(), keep_going_pass_signal(), keep_going_stepped_thread(), linux_make_corefile_notes(), process_stratum_target::maybe_add_resumed_with_pending_wait_status(), process_stratum_target::maybe_remove_resumed_with_pending_wait_status(), notify_thread_exited(), mi_interp::on_normal_stop(), pd_update(), prepare_one_step(), remote_target::print_one_stopped_thread(), proceed(), proceed_after_vfork_done(), proceed_resume_thread_checked(), proceed_thread(), ps_getpid(), random_pending_event_thread(), record_btrace_cancel_resume(), record_btrace_resume_thread(), registers_changed_thread(), restart_threads(), resume_1(), save_waitstatus(), remote_target::select_thread_for_ambiguous_stop_reply(), set_last_target_status_stopped(), set_running(), set_running_thread(), set_sig_thread_cmd(), set_step_frame(), set_step_info(), set_thread_exited(), should_print_thread(), switch_back_to_stepped_thread(), switch_to_thread_no_regs(), sync_threadlists(), thpy_get_ptid(), thread_alive(), thread_change_ptid(), thread_db_find_new_threads_2(), thread_db_find_thread_from_tid(), linux_nat_target::thread_name(), windows_nat_target::thread_name(), nbsd_nat_target::thread_name(), amd_dbgapi_target::thread_name(), thread_target_id_str(), try_thread_db_load_1(), ravenscar_thread_target::wait(), record_btrace_target::wait(), and ~thread_info().

◆ resumed_with_pending_wait_status_node

intrusive_list_node<thread_info> thread_info::resumed_with_pending_wait_status_node

◆ stack_temporaries

std::vector<struct value *> thread_info::stack_temporaries

◆ stack_temporaries_enabled

bool thread_info::stack_temporaries_enabled = false

◆ state

enum thread_state thread_info::state = THREAD_STOPPED

◆ step_after_step_resume_breakpoint

int thread_info::step_after_step_resume_breakpoint = 0

◆ step_over_list_node

intrusive_list_node<thread_info> thread_info::step_over_list_node

Definition at line 543 of file gdbthread.h.

Referenced by thread_is_in_step_over_chain().

◆ stepped_breakpoint

int thread_info::stepped_breakpoint = 0

◆ stepping_over_breakpoint

int thread_info::stepping_over_breakpoint = 0

◆ stepping_over_watchpoint

int thread_info::stepping_over_watchpoint = 0

◆ stop_requested

int thread_info::stop_requested = 0

The documentation for this class was generated from the following files: