diff options
author | Stan Shebs <shebs@codesourcery.com> | 2010-01-06 04:20:27 +0000 |
---|---|---|
committer | Stan Shebs <shebs@codesourcery.com> | 2010-01-06 04:20:27 +0000 |
commit | 7a697b8dd7ac3c14e35ae3026d955aeae3ecc054 (patch) | |
tree | 62009f9b707ae6f18c12be8956f7b1e5fc586a7a /gdb/doc | |
parent | 737a160ed9bb7bbe1ac8ebea1cdc27438213c247 (diff) | |
download | gdb-7a697b8dd7ac3c14e35ae3026d955aeae3ecc054.zip gdb-7a697b8dd7ac3c14e35ae3026d955aeae3ecc054.tar.gz gdb-7a697b8dd7ac3c14e35ae3026d955aeae3ecc054.tar.bz2 |
Add fast tracepoints.
* arch-utils.h (default_fast_tracepoint_valid_at): Declare.
* arch-utils.c (default_fast_tracepoint_valid_at): New function.
* breakpoint.h (enum bptype): Add bp_fast_tracepoint.
* breakpoint.c (tracepoint_type): New function.
(ALL_TRACEPOINTS): Use it.
(should_be_inserted): Ditto.
(bpstat_check_location): Ditto.
(print_one_breakpoint_location): Ditto.
(user_settable_breakpoint): Ditto.
(set_breakpoint_location_function): Ditto.
(disable_breakpoints_in_shlibs): Ditto.
(delete_trace_command): Ditto.
(print_it_typical): Add bp_fast_tracepoint case.
(bpstat_what): Ditto.
(print_one_breakpoint_location): Ditto.
(allocate_bp_location): Ditto.
(mention): Ditto.
(breakpoint_re_set_one): Ditto.
(disable_command): Ditto.
(enable_command): Ditto.
(check_fast_tracepoint_sals): New function.
(break_command_really): Call it.
(ftrace_command): New function.
(_initialize_breakpoint): Add ftrace command.
* gdbarch.sh (fast_tracepoint_valid_at): New.
* gdbarch.h, gdbarch.c: Regenerate.
* i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
(i386_gdbarch_init): Use it.
* remote.c (struct remote_state): New field fast_tracepoints.
(PACKET_FastTracepoints): New packet config type.
(remote_fast_tracepoint_feature): New function.
(remote_protocol_features): Add FastTracepoints.
(remote_supports_fast_tracepoints): New function.
(_initialize_remote): Add FastTracepoints.
* tracepoint.c (download_tracepoint): Add fast tracepoint option.
* NEWS: Mention fast tracepoints.
* gdb.texinfo (Create and Delete Tracepoints): Describe fast
tracepoints.
(Tracepoint Packets): Describe remote protocol for fast
tracepoints.
* gdb.trace/tracecmd.exp: Test ftrace.
Diffstat (limited to 'gdb/doc')
-rw-r--r-- | gdb/doc/ChangeLog | 7 | ||||
-rw-r--r-- | gdb/doc/gdb.texinfo | 36 |
2 files changed, 36 insertions, 7 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index deb3a14..48d187b 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,10 @@ +2010-01-05 Stan Shebs <stan@codesourcery.com> + + * gdb.texinfo (Create and Delete Tracepoints): Describe fast + tracepoints. + (Tracepoint Packets): Describe remote protocol for fast + tracepoints. + 2010-01-01 Joel Brobecker <brobecker@adacore.com> Update the "Start of New Year Procedure". diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index d0997b3..d23c675 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -9323,6 +9323,11 @@ expressions and ignore counts on tracepoints have no effect, and tracepoints cannot run @value{GDBN} commands when they are hit. Tracepoints may not be thread-specific either. +@cindex fast tracepoints +Some targets may support @dfn{fast tracepoints}, which are inserted in +a different way (such as with a jump instead of a trap), that is +faster but possibly restricted in where they may be installed. + This section describes commands to set tracepoints and associated conditions and actions. @@ -9378,6 +9383,20 @@ if the value is nonzero---that is, if @var{cond} evaluates as true. @xref{Tracepoint Conditions, ,Tracepoint Conditions}, for more information on tracepoint conditions. +@item ftrace @var{location} [ if @var{cond} ] +@cindex set fast tracepoint +@kindex ftrace +The @code{ftrace} command sets a fast tracepoint. For targets that +support them, fast tracepoints will use a more efficient but possibly +less general technique to trigger data collection, such as a jump +instruction instead of a trap, or some sort of hardware support. It +may not be possible to create a fast tracepoint at the desired +location, in which case the command will exit with an explanatory +message. + +@value{GDBN} handles arguments to @code{ftrace} exactly as for +@code{trace}. + @vindex $tpnum @cindex last tracepoint number @cindex recent tracepoint number @@ -29975,16 +29994,19 @@ tracepoints (@pxref{Tracepoints}). @table @samp -@item QTDP:@var{n}:@var{addr}:@var{ena}:@var{step}:@var{pass}[:X@var{len},@var{bytes}]@r{[}-@r{]} +@item QTDP:@var{n}:@var{addr}:@var{ena}:@var{step}:@var{pass}[:F@var{flen}][:X@var{len},@var{bytes}]@r{[}-@r{]} Create a new tracepoint, number @var{n}, at @var{addr}. If @var{ena} is @samp{E}, then the tracepoint is enabled; if it is @samp{D}, then the tracepoint is disabled. @var{step} is the tracepoint's step -count, and @var{pass} is its pass count. If an @samp{X} is present, -it introduces a tracepoint condition, which consists of a hexadecimal -length, followed by a comma and hex-encoded bytes, in a manner similar -to action encodings as described below. If the trailing @samp{-} is -present, further @samp{QTDP} packets will follow to specify this -tracepoint's actions. +count, and @var{pass} is its pass count. If an @samp{F} is present, +then the tracepoint is to be a fast tracepoint, and the @var{flen} is +the number of bytes that the target should copy elsewhere to make room +for the tracepoint. If an @samp{X} is present, it introduces a +tracepoint condition, which consists of a hexadecimal length, followed +by a comma and hex-encoded bytes, in a manner similar to action +encodings as described below. If the trailing @samp{-} is present, +further @samp{QTDP} packets will follow to specify this tracepoint's +actions. Replies: @table @samp |