#include "breakpoint.h"
#include "target.h"
+#include "memrange.h"
/* A trace state variable is a value managed by a target being
- traced. A trace state variable (or tsv for short) can be accessed
+ traced. A trace state variable (or tsv for short) can be accessed
and assigned to by tracepoint actions and conditionals, but is not
part of the program being traced, and it doesn't have to be
- collected. Effectively the variables are scratch space for
+ collected. Effectively the variables are scratch space for
tracepoints. */
struct trace_state_variable
extern void (*deprecated_trace_find_hook) (char *arg, int from_tty);
extern void (*deprecated_trace_start_stop_hook) (int start, int from_tty);
-int get_traceframe_number (void);
-void set_traceframe_number (int);
+/* Returns the current traceframe number. */
+extern int get_traceframe_number (void);
+
+/* Make the traceframe NUM be the current GDB trace frame number, and
+ do nothing more. In particular, this does not flush the
+ register/frame caches or notify the target about the trace frame
+ change, so that is can be used when we need to momentarily access
+ live memory. Targets lazily switch their current traceframe to
+ match GDB's traceframe number, at the appropriate times. */
+extern void set_traceframe_number (int);
+
+/* Make the traceframe NUM be the current trace frame, all the way to
+ the target, and flushes all global state (register/frame caches,
+ etc.). */
+extern void set_current_traceframe (int num);
+
struct cleanup *make_cleanup_restore_current_traceframe (void);
+struct cleanup *make_cleanup_restore_traceframe_number (void);
void free_actions (struct breakpoint *);
extern void validate_actionline (char **, struct breakpoint *);
extern void trace_save (const char *filename, int target_does_save);
+extern struct traceframe_info *parse_traceframe_info (const char *tframe_info);
+
+extern int traceframe_available_memory (VEC(mem_range_s) **result,
+ CORE_ADDR memaddr, ULONGEST len);
+
#endif /* TRACEPOINT_H */