/* Interface between GDB and target environments, including files and processes
- Copyright (C) 1990-2016 Free Software Foundation, Inc.
+ Copyright (C) 1990-2017 Free Software Foundation, Inc.
Contributed by Cygnus Support. Written by John Gilmore.
#include "vec.h"
#include "gdb_signals.h"
#include "btrace.h"
+#include "record.h"
#include "command.h"
#include "break-common.h" /* For enum target_hw_bp_type. */
ENV is the environment vector to pass. Errors reported with error().
On VxWorks and various standalone systems, we ignore exec_file. */
void (*to_create_inferior) (struct target_ops *,
- char *, char *, char **, int);
+ const char *, const std::string &,
+ char **, int);
void (*to_post_startup_inferior) (struct target_ops *, ptid_t)
TARGET_DEFAULT_IGNORE ();
int (*to_insert_fork_catchpoint) (struct target_ops *, int)
TARGET_DEFAULT_RETURN (0);
void (*to_update_thread_list) (struct target_ops *)
TARGET_DEFAULT_IGNORE ();
- char *(*to_pid_to_str) (struct target_ops *, ptid_t)
+ const char *(*to_pid_to_str) (struct target_ops *, ptid_t)
TARGET_DEFAULT_FUNC (default_pid_to_str);
- char *(*to_extra_thread_info) (struct target_ops *, struct thread_info *)
+ const char *(*to_extra_thread_info) (struct target_ops *, struct thread_info *)
TARGET_DEFAULT_RETURN (NULL);
const char *(*to_thread_name) (struct target_ops *, struct thread_info *)
TARGET_DEFAULT_RETURN (NULL);
const struct btrace_target_info *)
TARGET_DEFAULT_RETURN (NULL);
+ /* Current recording method. */
+ enum record_method (*to_record_method) (struct target_ops *, ptid_t ptid)
+ TARGET_DEFAULT_RETURN (RECORD_METHOD_NONE);
+
/* Stop trace recording. */
void (*to_stop_recording) (struct target_ops *)
TARGET_DEFAULT_IGNORE ();
is returned. */
VEC(mem_region_s) *target_memory_map (void);
+/* Erases all flash memory regions on the target. */
+void flash_erase_command (char *cmd, int from_tty);
+
/* Erase the specified flash region. */
void target_flash_erase (ULONGEST address, LONGEST length);
extern int target_terminal_is_ours (void);
-/* Initialize the terminal settings we record for the inferior,
- before we actually run the inferior. */
-
-extern void target_terminal_init (void);
-
-/* Put the inferior's terminal settings into effect. This is
- preparation for starting or resuming the inferior. This is a no-op
- unless called with the main UI as current UI. */
-
-extern void target_terminal_inferior (void);
+/* For target_terminal_init, target_terminal_inferior and
+ target_terminal_ours, see target/target.h. */
/* Put some of our terminal settings into effect, enough to get proper
results from our output, but do not change into or out of RAW mode
extern void target_terminal_ours_for_output (void);
-/* Put our terminal settings into effect. First record the inferior's
- terminal settings so they can be restored properly later. This is
- a no-op unless called with the main UI as current UI. */
-
-extern void target_terminal_ours (void);
-
/* Return true if the target stack has a non-default
"to_terminal_ours" method. */
`process xyz', but on some systems it may contain
`process xyz thread abc'. */
-extern char *target_pid_to_str (ptid_t ptid);
+extern const char *target_pid_to_str (ptid_t ptid);
-extern char *normal_pid_to_str (ptid_t ptid);
+extern const char *normal_pid_to_str (ptid_t ptid);
/* Return a short string describing extra information about PID,
e.g. "sleeping", "runnable", "running on LWP 3". Null return value
/* Adds a command ALIAS for target T and marks it deprecated. This is useful
for maintaining backwards compatibility when renaming targets. */
-extern void add_deprecated_target_alias (struct target_ops *t, char *alias);
+extern void add_deprecated_target_alias (struct target_ops *t,
+ const char *alias);
extern void push_target (struct target_ops *);
/* See to_delete_record in struct target_ops. */
extern void target_delete_record (void);
+/* See to_record_method. */
+extern enum record_method target_record_method (ptid_t ptid);
+
/* See to_record_is_replaying in struct target_ops. */
extern int target_record_is_replaying (ptid_t ptid);