[RFC,3/3] gdb: remove inferior continuations
Checks
Context |
Check |
Description |
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_build--master-arm |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_check--master-aarch64 |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_check--master-arm |
success
|
Testing passed
|
Commit Message
Remove the continuation mechanism. It is not used anymore.
---
gdb/inf-loop.c | 5 -----
gdb/inferior.c | 19 -------------------
gdb/inferior.h | 11 -----------
3 files changed, 35 deletions(-)
@@ -51,11 +51,6 @@ inferior_event_handler (enum inferior_event_type event_type)
target_async (false);
}
- /* Do all continuations associated with the whole inferior (not
- a particular thread). */
- if (inferior_ptid != null_ptid)
- current_inferior ()->do_all_continuations ();
-
/* When running a command list (from a user command, say), these
are only run when the command list is all done. */
if (current_ui->async)
@@ -77,8 +77,6 @@ inferior::~inferior ()
that target, leaving its reference count artificially high. However,
this is not critical as the dummy_target is a singleton. */
gdb_assert (m_target_stack.top ()->stratum () == dummy_stratum);
-
- m_continuations.clear ();
}
inferior::inferior (int pid_)
@@ -184,23 +182,6 @@ inferior::set_arch (gdbarch *arch)
registers_changed_ptid (proc_target, ptid_t (this->pid));
}
-void
-inferior::add_continuation (std::function<void ()> &&cont)
-{
- m_continuations.emplace_front (std::move (cont));
-}
-
-void
-inferior::do_all_continuations ()
-{
- while (!m_continuations.empty ())
- {
- auto iter = m_continuations.begin ();
- (*iter) ();
- m_continuations.erase (iter);
- }
-}
-
/* Notify interpreters and observers that inferior INF was added. */
static void
@@ -499,14 +499,6 @@ class inferior : public refcounted_object,
/* Delete all threads in the thread list, silently. */
void clear_thread_list ();
- /* Continuations-related methods. A continuation is an std::function
- to be called to finish the execution of a command when running
- GDB asynchronously. A continuation is executed after any thread
- of this inferior stops. Continuations are used by the attach
- command and the remote target when a new inferior is detected. */
- void add_continuation (std::function<void ()> &&cont);
- void do_all_continuations ();
-
/* Set/get file name for default use for standard in/out in the inferior.
On Unix systems, we try to make TERMINAL_NAME the inferior's controlling
@@ -672,9 +664,6 @@ class inferior : public refcounted_object,
/* The name of terminal device to use for I/O. */
std::string m_terminal;
- /* The list of continuations. */
- std::list<std::function<void ()>> m_continuations;
-
/* The arguments string to use when running. */
std::string m_args;