Aggregation Walkers
The libdtrace
library provides control over how to handle the data from the aggregations. By default, dtrace
outputs the elements of an aggregation sorted by the values stored in the aggregation. The API provides a number of options to print the values in aggregations. It also provides the ability to process the aggregations in alternate ways rather than printing the keys and values. The available functions to sort the output order are:
-
By value – dtrace_aggregate_walk_valsorted() Function
-
Reverse order by key – dtrace_aggregate_walk_keyrevsorted() Function
-
Reverse order by value – dtrace_aggregate_walk_valrevsorted() Function
-
First by key and then by aggregation variable ID – dtrace_aggregate_walk_keyvarsorted() Function
-
First by value and then by aggregation variable ID – dtrace_aggregate_walk_valvarsorted() Function
-
First reverse order by key and then by aggregation variable ID – dtrace_aggregate_walk_keyvarrevsorted() Function
-
First reverse order by value and then by aggregation variable ID – dtrace_aggregate_walk_valvarrevsorted() Function