qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Mark Wu <wudxw@linux.vnet.ibm.com>
To: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Cc: Mark Wu <wudxw@linux.vnet.ibm.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 6/6] trace: Update doc for trace events group
Date: Thu, 13 Oct 2011 01:14:19 +0800	[thread overview]
Message-ID: <1318439659-7525-7-git-send-email-wudxw@linux.vnet.ibm.com> (raw)
In-Reply-To: <1318439659-7525-1-git-send-email-wudxw@linux.vnet.ibm.com>


Signed-off-by: Mark Wu <wudxw@linux.vnet.ibm.com>
---
 docs/tracing.txt |   29 ++++++++++++++++++++++++++---
 1 files changed, 26 insertions(+), 3 deletions(-)

diff --git a/docs/tracing.txt b/docs/tracing.txt
index 95ca16c..2bd4824 100644
--- a/docs/tracing.txt
+++ b/docs/tracing.txt
@@ -16,6 +16,7 @@ for debugging, profiling, and observing execution.
 
    echo bdrv_aio_readv   > /tmp/events
    echo bdrv_aio_writev >> /tmp/events
+   echo group:virtio >> /tmp/events
 
 3. Run the virtual machine to produce a trace file:
 
@@ -53,6 +54,16 @@ source code like this:
         return ptr;
     }
 
+== Trace events group ==
+
+Trace events group is used to represent a set of trace events added for the same
+component or feature. Each trace events group starts with a line containing
+"group_start:GroupName" and end with a line containing "group_end". The range of
+a trace events group is determined by the "tracetool" script when it processes
+the "trace-events" file. You can change the state of a group of trace events at
+one time through trace events group.
+
+
 === Declaring trace events ===
 
 The "tracetool" script produces the trace.h header file which is included by
@@ -106,8 +117,8 @@ respectively.  This ensures portability between 32- and 64-bit platforms.
 
 == Generic interface and monitor commands ==
 
-You can programmatically query and control the dynamic state of trace events
-through a backend-agnostic interface:
+You can programmatically query and control the dynamic state of trace events or
+groups through a backend-agnostic interface:
 
 * trace_print_events
 
@@ -122,6 +133,11 @@ through a backend-agnostic interface:
     [...]
     trace_event_set_state("virtio_irq", false); /* disable */
 
+* trace_print_groups
+
+* trace_event_group_set_state
+  Enables or disables a given group of trace events at runtime inside QEMU.
+
 Note that some of the backends do not provide an implementation for this
 interface, in which case QEMU will just print a warning.
 
@@ -131,12 +147,19 @@ This functionality is also provided through monitor commands:
   View available trace events and their state.  State 1 means enabled, state 0
   means disabled.
 
+* info trace-groups
+  View available trace event groups and their state.  State 1 means enabled, state 0
+  means disabled.
+
 * trace-event NAME on|off
   Enable/disable a given trace event.
 
+* trace-group NAME on|off
+  Enable/disable a given trace event group.
+
 The "-trace events=<file>" command line argument can be used to enable the
 events listed in <file> from the very beginning of the program. This file must
-contain one event name per line.
+contain one event name or one group name, which is prefixed by "group:".
 
 == Trace backends ==
 
-- 
1.7.1

  parent reply	other threads:[~2011-10-12 17:15 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-12 17:14 [Qemu-devel] [PATCH 0/6] trace: Add support for trace events grouping Mark Wu
2011-10-12 17:14 ` [Qemu-devel] [PATCH 1/6] trace: Make "tracetool" generate a group list Mark Wu
2011-10-14  1:48   ` Sheldon
2011-10-12 17:14 ` [Qemu-devel] [PATCH 2/6] trace: Add HMP monitor commands for trace events group Mark Wu
2011-10-12 17:14 ` [Qemu-devel] [PATCH 3/6] trace: Add trace events group implementation in the backend "simple" Mark Wu
2011-10-12 20:46   ` Ryan Harper
2011-10-12 17:14 ` [Qemu-devel] [PATCH 4/6] trace: Add trace events group implementation in the backend "stderr" Mark Wu
2011-10-12 17:14 ` [Qemu-devel] [PATCH 5/6] trace: Enable "-trace events" argument to control initial state of groups Mark Wu
2011-10-12 17:14 ` Mark Wu [this message]
2011-10-13  8:10 ` [Qemu-devel] [PATCH 0/6] trace: Add support for trace events grouping Mark Wu
2011-10-14 12:16   ` Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1318439659-7525-7-git-send-email-wudxw@linux.vnet.ibm.com \
    --to=wudxw@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).