From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:44654) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UYEjK-0003Ux-Qv for qemu-devel@nongnu.org; Fri, 03 May 2013 08:04:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UYEgH-00049A-1f for qemu-devel@nongnu.org; Fri, 03 May 2013 08:01:56 -0400 Received: from mx1.redhat.com ([209.132.183.28]:32741) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UYEgG-00048o-P0 for qemu-devel@nongnu.org; Fri, 03 May 2013 08:01:40 -0400 From: Stefan Hajnoczi Date: Fri, 3 May 2013 14:01:25 +0200 Message-Id: <1367582485-15579-5-git-send-email-stefanha@redhat.com> In-Reply-To: <1367582485-15579-1-git-send-email-stefanha@redhat.com> References: <1367582485-15579-1-git-send-email-stefanha@redhat.com> Subject: [Qemu-devel] [PATCH 4/4] trace: document ftrace backend List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Anthony Liguori , Eiichi Tsukata , Stefan Hajnoczi From: Eiichi Tsukata Add documentation of ftrace backend. Signed-off-by: Eiichi Tsukata Signed-off-by: Stefan Hajnoczi --- docs/tracing.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/docs/tracing.txt b/docs/tracing.txt index cf53c17..60ff9c5 100644 --- a/docs/tracing.txt +++ b/docs/tracing.txt @@ -175,6 +175,22 @@ unless you have specific needs for more advanced backends. The "simple" backend currently does not capture string arguments, it simply records the char* pointer value instead of the string that is pointed to. +=== Ftrace === + +The "ftrace" backend writes trace data to ftrace marker. This effectively +sends trace events to ftrace ring buffer, and you can compare qemu trace +data and kernel(especially kvm.ko when using KVM) trace data. + +if you use KVM, enable kvm events in ftrace: + + # echo 1 > /sys/kernel/debug/tracing/events/kvm/enable + +After running qemu by root user, you can get the trace: + + # cat /sys/kernel/debug/tracing/trace + +Restriction: "ftrace" backend is restricted to Linux only. + ==== Monitor commands ==== * trace-file on|off|flush|set -- 1.8.1.4