WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Hi,something about the xentrace tool

To: "Rob Gardner" <rob.gardner@xxxxxx>
Subject: Re: [Xen-devel] Hi,something about the xentrace tool
From: NAHieu <nahieu@xxxxxxxxx>
Date: Wed, 14 Jun 2006 12:47:13 +0900
Cc: xen-tools@xxxxxxxxxxxxxxxxxxx, ryanh@xxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxx, rickey berkeley <rickey.berkeley@xxxxxxxxx>, xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 13 Jun 2006 20:47:53 -0700
Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Fc7yCBOQm477JE5QQWRJrVQE1eloPJ5kSvSHF/SaRV9EHDi73uLZL/+xDU26ctMkdDmlHWxQX/EOL8Li7nPH32n3uZ5YUBCnYYA9LHXXcteowYPmu5dA7u4/8My3zS3dhoksulLV/bzicN15l5bkqL91Q0cL7Vo1j7x5zt84n/E=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <448EF500.7070506@xxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <8061f8830606110617x1ebaf6bo17b61b854ceda6ce@xxxxxxxxxxxxxx> <20060612153032.GB1694@xxxxxxxxxx> <8061f8830606131011w732d1501x6fb81c37e1239553@xxxxxxxxxxxxxx> <448EF500.7070506@xxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Hi Rob,


On 6/14/06, Rob Gardner <rob.gardner@xxxxxx> wrote:
rickey berkeley wrote:
> Based on trace source code(xen/common/trace.c),dom0 tracing the event
> which are enabled.
>
> xen initialize tracing buffer for each cpu,trace buffer size (in
> pages) in kenel space is defined by opt_tbuf_size.
> The tracing buf use loop structure.
>
> I guess when the tracing data increase rapidly ,and xentrace tool in
> user space does not take them immediately.
> Some tracing data will lost.Maybe relayfs or something else can solve
> this problem.
>

I added a basic flow control mechanism to the trace buffer system a few
months ago. You can see an example of how to use it in tools/xenmon. The
way it works is that as trace records are generated, a software
interrupt is generated when the trace buffer gets filled to a certain
point. The user space tools can use select() on an event channel to find
out about these interrupts. See tools/xenmon/xenbaked.c for exact
programming details. This code has not been copied into xentrace yet;
Feel free to do so yourself if you think it's necessary.

Would you explain a little bit more on how you handle the overflow? If
the userspace detects that event, what it does then?

Usually if there is no more space available in kernel buffer, what
will you do? Drop some data, and hope that the userspace will come up
to free some for more space in the future? Or if you don't drop them,
just block there and wait for the userspace to come to free some?

I believe that there are few tactics for this problems, and what we
should do depends on situations.

Thanks.
H

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel