summaryrefslogtreecommitdiffstats
path: root/testsuite/systemtap.maps/linear_nearlyempty.stp
blob: f0b706073ee94cfad74ec2db55ea72e199dfd40a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# test that we can check the count of an empty array

global agg

probe begin
{
	agg <<< 444
	agg <<< 999
	printf("count=%d\n", @count(agg))
	if (@count(agg) > 0) {
		printf("sum=%d\n", @sum(agg))
        	printf("min=%d\n", @min(agg))
	        printf("max=%d\n", @max(agg))
        	printf("avg=%d\n", @avg(agg))
	        print(@hist_linear(agg, 0, 1500, 50))
	}
	exit()
}