|
GDB (xrefs)
|
#include "defs.h"#include "run-on-main-thread.h"#include "ser-event.h"#include <thread>#include <mutex>#include "gdbsupport/event-loop.h"Go to the source code of this file.
Functions | |
| static void | run_events (int error, gdb_client_data client_data) |
| void | run_on_main_thread (std::function< void()> &&func) |
| bool | is_main_thread () |
| void | _initialize_run_on_main_thread () |
Variables | |
| static struct serial_event * | runnable_event |
| static std::vector< std::function< void()> > | runnables |
| static std::mutex | runnable_mutex |
| static std::thread::id | main_thread_id |
| static bool | main_thread_id_initialized = false |
| void _initialize_run_on_main_thread | ( | ) |
Definition at line 123 of file run-on-main-thread.c.
Referenced by initialize_all_files().
| bool is_main_thread | ( | ) |
Definition at line 104 of file run-on-main-thread.c.
References main_thread_id, and main_thread_id_initialized.
Referenced by cooked_index::cooked_index(), main(), maybe_quit(), wait_for_index_cache(), and cooked_index::~cooked_index().
|
static |
Definition at line 51 of file run-on-main-thread.c.
References runnable_event, runnable_mutex, runnables, and serial_event_clear().
| void run_on_main_thread | ( | std::function< void()> && | func | ) |
Definition at line 88 of file run-on-main-thread.c.
References func, runnable_event, runnable_mutex, runnables, and serial_event_set().
Referenced by gdb_demangle(), gdbpy_post_event(), and selftests::main_thread_tests::set_done().
|
static |
Definition at line 44 of file run-on-main-thread.c.
Referenced by is_main_thread().
|
static |
Definition at line 98 of file run-on-main-thread.c.
Referenced by is_main_thread().
|
static |
Definition at line 30 of file run-on-main-thread.c.
Referenced by run_events(), and run_on_main_thread().
|
static |
Definition at line 40 of file run-on-main-thread.c.
Referenced by run_events(), and run_on_main_thread().
|
static |
Definition at line 34 of file run-on-main-thread.c.
Referenced by run_events(), and run_on_main_thread().