Tests: Add a trace statistics utility
authorChristian Babeux <christian.babeux@efficios.com>
Tue, 16 Oct 2012 18:33:21 +0000 (14:33 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Fri, 19 Oct 2012 19:20:09 +0000 (15:20 -0400)
commitd8865498212833e7b4d6d67b81426a4ddc04bafe
tree0b27b6c8f35531439d2f652a771c36cfe414b656
parentb2a325c4360993fd3789a168c2225ec239fa149e
Tests: Add a trace statistics utility

The babelstats script output statistics on fields values for
a particular tracepoint. At the moment, the script only show
minimum and maximum value for each fields of a particular
tracepoint.

The trace must be in the babeltrace text format. It can be
passed via stdin.

The script output this format:
field_name min max

Sample usage:

> babeltrace sometracedir | babelstats.pl --tracepoint tp:tptest

_seqfield1_length 4 4
seqfield2 "test" "test"
stringfield2 "\*" "\*"
floatfield 2222 2222
netintfieldhex 0x0 0x63
_seqfield2_length 4 4
longfield 0 99
netintfield 0 99
intfield2 0x0 0x63
intfield 0 99
stringfield "test" "test"
doublefield 2 2
arrfield2 "test" "test"

Use case:
This script could be useful to validate that fields values
are within some predefined expected ranges.

Signed-off-by: Christian Babeux <christian.babeux@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
tests/tools/filtering/Makefile.am
tests/tools/filtering/babelstats.pl [new file with mode: 0755]
This page took 0.024956 seconds and 4 git commands to generate.