From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32455 invoked by alias); 9 Mar 2013 03:49:04 -0000 Received: (qmail 32408 invoked by uid 22791); 9 Mar 2013 03:49:03 -0000 X-SWARE-Spam-Status: No, hits=-4.6 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,TW_BM X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 09 Mar 2013 03:48:51 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1UEAmB-0003bv-0i from Yao_Qi@mentor.com for gdb-patches@sourceware.org; Fri, 08 Mar 2013 19:48:51 -0800 Received: from SVR-ORW-FEM-03.mgc.mentorg.com ([147.34.97.39]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Fri, 8 Mar 2013 19:48:50 -0800 Received: from qiyao.dyndns.dyndns.org (147.34.91.1) by svr-orw-fem-03.mgc.mentorg.com (147.34.97.39) with Microsoft SMTP Server id 14.1.289.1; Fri, 8 Mar 2013 19:48:49 -0800 From: Yao Qi To: Subject: [PATCH v3 04/15] ctf doc and NEWS. Date: Sat, 09 Mar 2013 03:49:00 -0000 Message-ID: <1362800844-27940-5-git-send-email-yao@codesourcery.com> In-Reply-To: <1362800844-27940-1-git-send-email-yao@codesourcery.com> References: <1362800844-27940-1-git-send-email-yao@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2013-03/txt/msg00395.txt.bz2 The doc bit was reviewed by Eli here http://sourceware.org/ml/gdb-patches/2013-02/msg00695.html and comments are addressed. 2013-03-08 Hui Zhu Yao Qi * gdb.texinfo (Trace Files): Add "tsave -ctf" and target ctf. * NEWS: Mention these changes. --- gdb/NEWS | 7 +++++++ gdb/doc/gdb.texinfo | 38 ++++++++++++++++++++++++++++++++------ 2 files changed, 39 insertions(+), 6 deletions(-) diff --git a/gdb/NEWS b/gdb/NEWS index 05fa498..dd03780 100644 --- a/gdb/NEWS +++ b/gdb/NEWS @@ -70,6 +70,8 @@ x86_64/Cygwin x86_64-*-cygwin* * The command 'info tracepoints' can now display 'installed on target' or 'not installed on target' for each non-pending location of tracepoint. +* The command 'tsave' can now support new option '-ctf' to save trace + buffer in Common Trace Format. * New configure options @@ -79,6 +81,9 @@ x86_64/Cygwin x86_64-*-cygwin* Release versions, on the other hand, are built without -lmcheck by default. The --enable-libmcheck/--disable-libmcheck configure options allow the user to override that default. +--with-babeltrace/--with-babeltrace-include/--with-babeltrace-lib + This configure option allows the user to build GDB with + libbabeltrace using which GDB can read Common Trace Format data. * New commands (for set/show, see "New options" below) @@ -154,6 +159,8 @@ show filename-display ** Output of the "-trace-status" command includes a "trace-file" field containing the name of the trace file being examined. This field is optional, and only present when examining a trace file. + ** The -trace-save MI command can optionally save trace buffer in Common + Trace Format now. * GDB now supports the "mini debuginfo" section, .gnu_debugdata. You must have the LZMA library available when configuring GDB for this diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index 5f39d2e..5f35483 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -12120,6 +12120,7 @@ of trace data, via the @code{target tfile} command. @kindex tsave @item tsave [ -r ] @var{filename} +@itemx tsave [-ctf] @var{dirname} Save the trace data to @var{filename}. By default, this command assumes that @var{filename} refers to the host filesystem, so if necessary @value{GDBN} will copy raw trace data up from the target and @@ -12128,16 +12129,41 @@ optional argument @code{-r} (``remote'') to direct the target to save the data directly into @var{filename} in its own filesystem, which may be more efficient if the trace buffer is very large. (Note, however, that @code{target tfile} can only read from files accessible to the host.) +By default, this command will save trace frame in tfile format. +You can supply the optional argument @code{-ctf} to save date in CTF +format. The @dfn{Common Trace Format} (CTF) is proposed as a trace format +that can be shared by multiple debugging and tracing tools. Please go to +@indicateurl{http://www.efficios.com/ctf} to get more information. @kindex target tfile @kindex tfile +@kindex target ctf +@kindex ctf @item target tfile @var{filename} -Use the file named @var{filename} as a source of trace data. Commands -that examine data work as they do with a live target, but it is not -possible to run any new trace experiments. @code{tstatus} will report -the state of the trace run at the moment the data was saved, as well -as the current trace frame you are examining. @var{filename} must be -on a filesystem accessible to the host. +@itemx target ctf @var{dirname} +Use the file named @var{filename} or directory named @var{dirname} as +a source of trace data. Commands that examine data work as they do with +a live target, but it is not possible to run any new trace experiments. +@code{tstatus} will report the state of the trace run at the moment +the data was saved, as well as the current trace frame you are examining. +@var{filename} or @var{dirname} must be on a filesystem accessible to +the host. + +@smallexample +(@value{GDBP}) target ctf ctf.ctf +(@value{GDBP}) tfind +Found trace frame 0, tracepoint 2 +39 ++a; /* set tracepoint 1 here */ +(@value{GDBP}) tdump +Data collected at tracepoint 2, trace frame 0: +i = 0 +a = 0 +b = 1 '\001' +c = @{"123", "456", "789", "123", "456", "789"@} +d = @{@{@{a = 1, b = 2@}, @{a = 3, b = 4@}@}, @{@{a = 5, b = 6@}, @{a = 7, b = 8@}@}@} +(@value{GDBP}) p b +$1 = 1 +@end smallexample @end table -- 1.7.7.6