Dan Magenheimer
2009-Apr-29 16:50 UTC
[Xen-devel] [PATCH] add long interrupt measurement capability
Hi Keir -- Since I see you are still taking boot-option patches for 3.4, I thought I''d retry this one which optionally measures cycles spent in each irq. I thought you had just decided it was too late for 3.4... if you rejected it for another reason, please let me know. Thanks, Dan> From: Dan Magenheimer > Sent: Tuesday, April 14, 2009 9:39 AM > To: Keir Fraser; Tian, Kevin; Xen-Devel (E-mail) > Subject: RE: [Xen-devel] million cycle interrupt > > But first, Keir, would you take this patch so that this > kind of issue can be more easily diagnosed in the future? > If you''re worried about the extra two global variable > reads, you could wrap an "#ifndef NDEBUG" around it > (with #else #define opt_measure_irqs 0), but it might > be nice to have this diagnostic capability in released > code._______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2009-Apr-29 18:03 UTC
[Xen-devel] Re: [PATCH] add long interrupt measurement capability
On 29/04/2009 17:50, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote:> Since I see you are still taking boot-option patches > for 3.4, I thought I''d retry this one which optionally > measures cycles spent in each irq. I thought > you had just decided it was too late for 3.4... if > you rejected it for another reason, please let me > know.I don''t think it has sufficient general utility to be applied. Anyone who would actually have the want and wit to run this option can apply the patch themselves. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dulloor
2009-May-08 00:14 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
Dan, Couldn''t you add this to xentrace ? -dulloor On Wed, Apr 29, 2009 at 2:03 PM, Keir Fraser <keir.fraser@eu.citrix.com>wrote:> On 29/04/2009 17:50, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote: > > > Since I see you are still taking boot-option patches > > for 3.4, I thought I''d retry this one which optionally > > measures cycles spent in each irq. I thought > > you had just decided it was too late for 3.4... if > > you rejected it for another reason, please let me > > know. > > I don''t think it has sufficient general utility to be applied. Anyone who > would actually have the want and wit to run this option can apply the patch > themselves. > > -- Keir > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dan Magenheimer
2009-May-08 21:36 UTC
RE: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
Perhaps. However measuring cycles is important and, more specifically, measuring MAX cycles spent across a set of interrupts. As a result, I suspect any code that measures this (regardless of whether the result is reported by xentrace or debug-key) would likely encounter the same objection from Keir. -----Original Message----- From: Dulloor [mailto:dulloor@gmail.com] Sent: Thursday, May 07, 2009 6:14 PM To: Keir Fraser Cc: Dan Magenheimer; Xen-Devel (E-mail) Subject: Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability Dan, Couldn''t you add this to xentrace ? -dulloor On Wed, Apr 29, 2009 at 2:03 PM, Keir Fraser <keir.fraser@eu.citrix.com> wrote: On 29/04/2009 17:50, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote:> Since I see you are still taking boot-option patches > for 3.4, I thought I''d retry this one which optionally > measures cycles spent in each irq. I thought > you had just decided it was too late for 3.4... if > you rejected it for another reason, please let me > know.I don''t think it has sufficient general utility to be applied. Anyone who would actually have the want and wit to run this option can apply the patch themselves. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Ian Pratt
2009-May-08 21:53 UTC
RE: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
> Perhaps. However measuring cycles is important and, more > specifically, measuring MAX cycles spent across a set of > interrupts. As a result, I suspect any code that measures > this (regardless of whether the result is reported by > xentrace or debug-key) would likely encounter the > same objection from Keir.I can''t imagine there''d be any objection to adding trace macros to record this. The xentrace log processing tool can then be updated to generate max or histogram values. Ian> -----Original Message----- > From: Dulloor [mailto:dulloor@gmail.com] > Sent: Thursday, May 07, 2009 6:14 PM > To: Keir Fraser > Cc: Dan Magenheimer; Xen-Devel (E-mail) > Subject: Re: [Xen-devel] Re: [PATCH] add long interrupt measurement > capability > > > Dan, Couldn''t you add this to xentrace ? > > -dulloor > > > On Wed, Apr 29, 2009 at 2:03 PM, Keir Fraser > <keir.fraser@eu.citrix.com> wrote: > > On 29/04/2009 17:50, "Dan Magenheimer" <dan.magenheimer@oracle.com> > wrote: > > > Since I see you are still taking boot-option patches > > for 3.4, I thought I''d retry this one which optionally > > measures cycles spent in each irq. I thought > > you had just decided it was too late for 3.4... if > > you rejected it for another reason, please let me > > know. > > > I don''t think it has sufficient general utility to be applied. Anyone > who > would actually have the want and wit to run this option can apply the > patch > themselves. > > -- Keir > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2009-May-09 07:56 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com> wrote:>> Perhaps. However measuring cycles is important and, more >> specifically, measuring MAX cycles spent across a set of >> interrupts. As a result, I suspect any code that measures >> this (regardless of whether the result is reported by >> xentrace or debug-key) would likely encounter the >> same objection from Keir. > > I can''t imagine there''d be any objection to adding trace macros to record > this. The xentrace log processing tool can then be updated to generate max or > histogram values.Yes, xentrace records would be okay. It''s adding another debug key and printing to Xen console for this purpose which I do not think is worthwhile. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dulloor
2009-May-09 09:12 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
Here is a xentrace patch. - Should irq_desc_measure_t move to some .h file ? - I have defined the new trace event in general class. Is it fine ? - I have defined tsc_in as volatile to avoid initializing it in the main code path. thanks dulloor On Sat, May 9, 2009 at 3:56 AM, Keir Fraser <keir.fraser@eu.citrix.com>wrote:> On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com> wrote: > > >> Perhaps. However measuring cycles is important and, more > >> specifically, measuring MAX cycles spent across a set of > >> interrupts. As a result, I suspect any code that measures > >> this (regardless of whether the result is reported by > >> xentrace or debug-key) would likely encounter the > >> same objection from Keir. > > > > I can''t imagine there''d be any objection to adding trace macros to record > > this. The xentrace log processing tool can then be updated to generate > max or > > histogram values. > > Yes, xentrace records would be okay. It''s adding another debug key and > printing to Xen console for this purpose which I do not think is > worthwhile. > > -- Keir > > >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dan Magenheimer
2009-May-10 00:58 UTC
RE: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
> > I can''t imagine there''d be any objection to adding trace > macros to record > > this. The xentrace log processing tool can then be updated > to generate max or > > histogram values. > > Yes, xentrace records would be okay. It''s adding another debug key and > printing to Xen console for this purpose which I do not think > is worthwhile.Well, for the record, the original patch does NOT add another debug key, it just adds data to an existing one. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Tian, Kevin
2009-May-11 04:50 UTC
RE: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
I guess you can handle it much simpler by stamping a record in both irq_enter and irq_exit. All the statistics jobs are left for xentrace script to digest. Also I'd call it as trace_irq instead of trace_guest_irq. :-) Thanks, Kevin ________________________________ From: xen-devel-bounces@lists.xensource.com [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Dulloor Sent: 2009年5月9日 17:12 To: Keir Fraser Cc: Ian Pratt; Xen-Devel (E-mail); Dan Magenheimer Subject: Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability Here is a xentrace patch. - Should irq_desc_measure_t move to some .h file ? - I have defined the new trace event in general class. Is it fine ? - I have defined tsc_in as volatile to avoid initializing it in the main code path. thanks dulloor On Sat, May 9, 2009 at 3:56 AM, Keir Fraser <keir.fraser@eu.citrix.com<mailto:keir.fraser@eu.citrix.com>> wrote: On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com<mailto:Ian.Pratt@eu.citrix.com>> wrote:>> Perhaps. However measuring cycles is important and, more >> specifically, measuring MAX cycles spent across a set of >> interrupts. As a result, I suspect any code that measures >> this (regardless of whether the result is reported by >> xentrace or debug-key) would likely encounter the >> same objection from Keir. > > I can't imagine there'd be any objection to adding trace macros to record > this. The xentrace log processing tool can then be updated to generate max or > histogram values.Yes, xentrace records would be okay. It's adding another debug key and printing to Xen console for this purpose which I do not think is worthwhile. -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dulloor
2009-May-11 08:39 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
- Changed the name to trace_irq :) - trace_irq dumps just tsc_in and tsc_out values in a single record. I guess there is no need to write two records (wasting trace-buf mem, more processing, additional logic in xentrace and/or xentrace_format). - xentrace_format does what Dan wanted. -dulloor 2009/5/11 Tian, Kevin <kevin.tian@intel.com>> I guess you can handle it much simpler by stamping a record in both > irq_enter and irq_exit. All the statistics jobs are left for xentrace script > to digest. > > Also I''d call it as trace_irq instead of trace_guest_irq. :-) > > Thanks, > Kevin > > ------------------------------ > *From:* xen-devel-bounces@lists.xensource.com [mailto: > xen-devel-bounces@lists.xensource.com] *On Behalf Of *Dulloor > *Sent:* 2009年5月9日 17:12 > *To:* Keir Fraser > *Cc:* Ian Pratt; Xen-Devel (E-mail); Dan Magenheimer > *Subject:* Re: [Xen-devel] Re: [PATCH] add long interrupt measurement > capability > > Here is a xentrace patch. > > - Should irq_desc_measure_t move to some .h file ? > - I have defined the new trace event in general class. Is it fine ? > > - I have defined tsc_in as volatile to avoid initializing it in the main > code path. > > thanks > dulloor > > On Sat, May 9, 2009 at 3:56 AM, Keir Fraser <keir.fraser@eu.citrix.com>wrote: > >> On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com> wrote: >> >> >> Perhaps. However measuring cycles is important and, more >> >> specifically, measuring MAX cycles spent across a set of >> >> interrupts. As a result, I suspect any code that measures >> >> this (regardless of whether the result is reported by >> >> xentrace or debug-key) would likely encounter the >> >> same objection from Keir. >> > >> > I can''t imagine there''d be any objection to adding trace macros to >> record >> > this. The xentrace log processing tool can then be updated to generate >> max or >> > histogram values. >> >> Yes, xentrace records would be okay. It''s adding another debug key and >> printing to Xen console for this purpose which I do not think is >> worthwhile. >> >> -- Keir >> >> >> >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Dulloor
2009-May-19 04:41 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
Hi Keir, Can you consider this for check-in. -dulloor 2009/5/11 Dulloor <dulloor@gmail.com>> - Changed the name to trace_irq :) > > - trace_irq dumps just tsc_in and tsc_out values in a single record. I > guess there is no need to write two records (wasting trace-buf mem, more > processing, additional logic in xentrace and/or xentrace_format). > > - xentrace_format does what Dan wanted. > > -dulloor > > 2009/5/11 Tian, Kevin <kevin.tian@intel.com> > > I guess you can handle it much simpler by stamping a record in both >> irq_enter and irq_exit. All the statistics jobs are left for xentrace script >> to digest. >> >> Also I''d call it as trace_irq instead of trace_guest_irq. :-) >> >> Thanks, >> Kevin >> >> ------------------------------ >> *From:* xen-devel-bounces@lists.xensource.com [mailto: >> xen-devel-bounces@lists.xensource.com] *On Behalf Of *Dulloor >> *Sent:* 2009年5月9日 17:12 >> *To:* Keir Fraser >> *Cc:* Ian Pratt; Xen-Devel (E-mail); Dan Magenheimer >> *Subject:* Re: [Xen-devel] Re: [PATCH] add long interrupt measurement >> capability >> >> Here is a xentrace patch. >> >> - Should irq_desc_measure_t move to some .h file ? >> - I have defined the new trace event in general class. Is it fine ? >> >> - I have defined tsc_in as volatile to avoid initializing it in the main >> code path. >> >> thanks >> dulloor >> >> On Sat, May 9, 2009 at 3:56 AM, Keir Fraser <keir.fraser@eu.citrix.com>wrote: >> >>> On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com> wrote: >>> >>> >> Perhaps. However measuring cycles is important and, more >>> >> specifically, measuring MAX cycles spent across a set of >>> >> interrupts. As a result, I suspect any code that measures >>> >> this (regardless of whether the result is reported by >>> >> xentrace or debug-key) would likely encounter the >>> >> same objection from Keir. >>> > >>> > I can''t imagine there''d be any objection to adding trace macros to >>> record >>> > this. The xentrace log processing tool can then be updated to generate >>> max or >>> > histogram values. >>> >>> Yes, xentrace records would be okay. It''s adding another debug key and >>> printing to Xen console for this purpose which I do not think is >>> worthwhile. >>> >>> -- Keir >>> >>> >>> >> >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Keir Fraser
2009-May-19 04:45 UTC
Re: [Xen-devel] Re: [PATCH] add long interrupt measurement capability
I applied it earlier today. On 18/05/2009 21:41, "Dulloor" <dulloor@gmail.com> wrote:> Hi Keir, > > Can you consider this for check-in. > > -dulloor > > 2009/5/11 Dulloor <dulloor@gmail.com> >> - Changed the name to trace_irq :) >> >> - trace_irq dumps just tsc_in and tsc_out values in a single record. I guess >> there is no need to write two records (wasting trace-buf mem, more >> processing, additional logic in xentrace and/or xentrace_format). >> >> - xentrace_format does what Dan wanted. >> >> -dulloor >> >> 2009/5/11 Tian, Kevin <kevin.tian@intel.com> >> >>> I guess you can handle it much simpler by stamping a record in both >>> irq_enter and irq_exit. All the statistics jobs are left for xentrace script >>> to digest. >>> >>> Also I''d call it as trace_irq instead of trace_guest_irq. :-) >>> >>> Thanks, >>> Kevin >>> >>>> >>>> >>>> >>>> From: xen-devel-bounces@lists.xensource.com >>>> [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of Dulloor >>>> Sent: 2009年5月9日 17:12 >>>> To: Keir Fraser >>>> Cc: Ian Pratt; Xen-Devel (E-mail); Dan Magenheimer >>>> >>>> Subject: Re: [Xen-devel] Re: [PATCH] add long interrupt measurement >>>> capability >>>> >>>> >>>> Here is a xentrace patch. >>>> >>>> - Should irq_desc_measure_t move to some .h file ? >>>> - I have defined the new trace event in general class. Is it fine ? >>>> >>>> - I have defined tsc_in as volatile to avoid initializing it in the main >>>> code path. >>>> >>>> thanks >>>> dulloor >>>> >>>> >>>> On Sat, May 9, 2009 at 3:56 AM, Keir Fraser <keir.fraser@eu.citrix.com> >>>> wrote: >>>> >>>>> >>>>> On 08/05/2009 22:53, "Ian Pratt" <Ian.Pratt@eu.citrix.com> wrote: >>>>> >>>>>>> Perhaps. However measuring cycles is important and, more >>>>>>> specifically, measuring MAX cycles spent across a set of >>>>>>> interrupts. As a result, I suspect any code that measures >>>>>>> this (regardless of whether the result is reported by >>>>>>> xentrace or debug-key) would likely encounter the >>>>>>> same objection from Keir. >>>>>> >>>>>> I can''t imagine there''d be any objection to adding trace macros to >>>>>> record >>>>>> this. The xentrace log processing tool can then be updated to generate >>>>>> max or >>>>>> histogram values. >>>>> >>>>> Yes, xentrace records would be okay. It''s adding another debug key and >>>>> printing to Xen console for this purpose which I do not think is >>>>> worthwhile. >>>>> >>>>> -- Keir >>>>> >>>>> >>>> >> > >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel