* fork-child.c (escape_bang_in_quoted_argument): New function.
[deliverable/binutils-gdb.git] / gdb / target.h
index e56207de5bcbb5cc1627189e2071e32e936d5644..e757b6701d92ad90ac3fa41cf3ad3ba75b965278 100644 (file)
 #if !defined (TARGET_H)
 #define TARGET_H
 
+struct objfile;
+struct ui_file;
+struct mem_attrib;
+
 /* This include file defines the interface between the main part
    of the debugger, and the part which is target-specific, or
    specific to the communications interface between us and the
@@ -193,9 +197,7 @@ struct target_ops
     void (*to_close) (int);
     void (*to_attach) (char *, int);
     void (*to_post_attach) (int);
-    void (*to_require_attach) (char *, int);
     void (*to_detach) (char *, int);
-    void (*to_require_detach) (int, char *, int);
     void (*to_resume) (ptid_t, int, enum target_signal);
     ptid_t (*to_wait) (ptid_t, struct target_waitstatus *);
     void (*to_post_wait) (ptid_t, int);
@@ -258,6 +260,7 @@ struct target_ops
     int (*to_remove_watchpoint) (CORE_ADDR, int, int);
     int (*to_insert_watchpoint) (CORE_ADDR, int, int);
     int (*to_stopped_by_watchpoint) (void);
+    int to_have_continuable_watchpoint;
     CORE_ADDR (*to_stopped_data_address) (void);
     int (*to_region_size_ok_for_hw_watchpoint) (int);
     void (*to_terminal_init) (void);
@@ -297,8 +300,6 @@ struct target_ops
     struct exception_event_record *(*to_get_current_exception_event) (void);
     char *(*to_pid_to_exec_file) (int pid);
     enum strata to_stratum;
-    struct target_ops
-     *DONT_USE;                        /* formerly to_next */
     int to_has_all_memory;
     int to_has_memory;
     int to_has_stack;
@@ -404,17 +405,6 @@ extern struct target_stack_item *target_stack;
 #define target_post_attach(pid) \
      (*current_target.to_post_attach) (pid)
 
-/* Attaches to a process on the target side, if not already attached.
-   (If already attached, takes no action.)
-
-   This operation can be used to follow the child process of a fork.
-   On some targets, such child processes of an original inferior process
-   are automatically under debugger control, and thus do not require an
-   actual attach operation.  */
-
-#define        target_require_attach(args, from_tty)   \
-     (*current_target.to_require_attach) (args, from_tty)
-
 /* Takes a program previously attached to and detaches it.
    The program may resume execution (some targets do, some don't) and will
    no longer stop on signals, etc.  We better not have left any breakpoints
@@ -424,21 +414,6 @@ extern struct target_stack_item *target_stack;
 
 extern void target_detach (char *, int);
 
-/* Detaches from a process on the target side, if not already dettached.
-   (If already detached, takes no action.)
-
-   This operation can be used to follow the parent process of a fork.
-   On some targets, such child processes of an original inferior process
-   are automatically under debugger control, and thus do require an actual
-   detach operation.
-
-   PID is the process id of the child to detach from.
-   ARGS is arguments typed by the user (e.g. a signal to send the process).
-   FROM_TTY says whether to be verbose or not.  */
-
-#define target_require_detach(pid, args, from_tty)     \
-     (*current_target.to_require_detach) (pid, args, from_tty)
-
 /* Resume execution of the target process PTID.  STEP says whether to
    single-step or to run free; SIGGNAL is the signal to be given to
    the target, or TARGET_SIGNAL_0 for no signal.  The caller may not
@@ -518,11 +493,11 @@ extern int child_xfer_memory (CORE_ADDR, char *, int, int,
    of bytes actually transfered is not defined) and ERR is set to a
    non-zero error indication.  */
 
-extern int 
-target_read_memory_partial (CORE_ADDR addr, char *buf, int len, int *err);
+extern int target_read_memory_partial (CORE_ADDR addr, char *buf, int len,
+                                      int *err);
 
-extern int 
-target_write_memory_partial (CORE_ADDR addr, char *buf, int len, int *err);
+extern int target_write_memory_partial (CORE_ADDR addr, char *buf, int len,
+                                       int *err);
 
 extern char *child_pid_to_exec_file (int);
 
@@ -808,11 +783,6 @@ extern void target_load (char *arg, int from_tty);
 #define target_get_current_exception_event() \
      (*current_target.to_get_current_exception_event) ()
 
-/* Pointer to next target in the chain, e.g. a core file and an exec file.  */
-
-#define        target_next \
-     (current_target.to_next)
-
 /* Does the target include all of memory, or only part of it?  This
    determines whether we look up the target chain for other parts of
    memory if this target can't satisfy a request.  */
@@ -866,15 +836,15 @@ extern void target_load (char *arg, int from_tty);
 #define target_async(CALLBACK,CONTEXT) \
      (current_target.to_async((CALLBACK), (CONTEXT)))
 
-/* This is to be used ONLY within run_stack_dummy(). It
-   provides a workaround, to have inferior function calls done in
-   sychronous mode, even though the target is asynchronous. After
+/* This is to be used ONLY within call_function_by_hand(). It provides
+   a workaround, to have inferior function calls done in sychronous
+   mode, even though the target is asynchronous. After
    target_async_mask(0) is called, calls to target_can_async_p() will
    return FALSE , so that target_resume() will not try to start the
    target asynchronously. After the inferior stops, we IMMEDIATELY
    restore the previous nature of the target, by calling
    target_async_mask(1). After that, target_can_async_p() will return
-   TRUE. ANY OTHER USE OF THIS FEATURE IS DEPRECATED. 
+   TRUE. ANY OTHER USE OF THIS FEATURE IS DEPRECATED.
 
    FIXME ezannoni 1999-12-13: we won't need this once we move
    the turning async on and off to the single execution commands,
@@ -998,6 +968,13 @@ extern void (*target_new_objfile_hook) (struct objfile *);
    (*current_target.to_stopped_by_watchpoint) ()
 #endif
 
+/* Non-zero if we have continuable watchpoints  */
+
+#ifndef HAVE_CONTINUABLE_WATCHPOINT
+#define HAVE_CONTINUABLE_WATCHPOINT \
+   (current_target.to_have_continuable_watchpoint)
+#endif
+
 /* HP-UX supplies these operations, which respectively disable and enable
    the memory page-protections that are used to implement hardware watchpoints
    on that platform.  See wait_for_inferior's use of these.  */
@@ -1136,8 +1113,8 @@ struct section_table
 /* Builds a section table, given args BFD, SECTABLE_PTR, SECEND_PTR.
    Returns 0 if OK, 1 on error.  */
 
-extern int
-build_section_table (bfd *, struct section_table **, struct section_table **);
+extern int build_section_table (bfd *, struct section_table **,
+                               struct section_table **);
 
 /* From mem-break.c */
 
@@ -1161,10 +1138,6 @@ extern void noprocess (void);
 
 extern void find_default_attach (char *, int);
 
-extern void find_default_require_attach (char *, int);
-
-extern void find_default_require_detach (int, char *, int);
-
 extern void find_default_create_inferior (char *, char *, char **);
 
 extern struct target_ops *find_run_target (void);
@@ -1173,8 +1146,8 @@ extern struct target_ops *find_core_target (void);
 
 extern struct target_ops *find_target_beneath (struct target_ops *);
 
-extern int
-target_resize_to_sections (struct target_ops *target, int num_added);
+extern int target_resize_to_sections (struct target_ops *target,
+                                     int num_added);
 
 extern void remove_target_sections (bfd *abfd);
 
This page took 0.025758 seconds and 4 git commands to generate.