pcp
[Top] [All Lists]

Re: [pcp] suitability of PCP for event tracing

To: nathans@xxxxxxxxxx
Subject: Re: [pcp] suitability of PCP for event tracing
From: Ken McDonell <kenj@xxxxxxxxxxxxxxxx>
Date: Mon, 29 Nov 2010 06:07:53 +1100
Cc: pcp@xxxxxxxxxxx, systemtap@xxxxxxxxxxxxxxxxxx
In-reply-to: <1290835727.3428.16.camel@bozo-laptop>
References: <876162548.141311290639523809.JavaMail.root@xxxxxxxxxxxxxxxxxxxxxx> <1290835727.3428.16.camel@bozo-laptop>
Reply-to: kenj@xxxxxxxxxxxxxxxx
On Sat, 2010-11-27 at 16:28 +1100, Ken McDonell wrote:

> Try this one for size ...
> 
> Add a new sort of "anonymous" PCP metric, such that the PMID is
> hard-coded for a small number of anon metrics as is the pmDesc (I'm
> thinking one per simple data type, semantics discrete, no units, no
> instance domain) and the "name", e.g. anon.u32 for a PM_TYPE_U32 metric
> with pmid 0:0:1.

Turns out this is really simple to implement on the back of derived
metrics ...

$ diffstat -p1 </tmp/patch.anon
 src/libpcp/src/derive.c       |   57
+++++++++++++++++++++++++++++++++++++++---
 src/libpcp/src/derive.h       |    1 
 src/libpcp/src/derive_fetch.c |    4 ++
 3 files changed, 58 insertions(+), 4 deletions(-)

$ pminfo -df anon

anon.32
    Data Type: 32-bit int  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!

anon.u32
    Data Type: 32-bit unsigned int  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!

anon.64
    Data Type: 64-bit int  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!

anon.u64
    Data Type: 64-bit unsigned int  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!

anon.float
    Data Type: float  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!

anon.double
    Data Type: double  InDom: PM_INDOM_NULL 0xffffffff
    Semantics: discrete  Units: none
No value(s) available!


<Prev in Thread] Current Thread [Next in Thread>