free(evsel);
}
-static inline void compute_deltas(struct perf_evsel *evsel,
- int cpu,
- struct perf_counts_values *count)
+void perf_evsel__compute_deltas(struct perf_evsel *evsel, int cpu,
+ struct perf_counts_values *count)
{
struct perf_counts_values tmp;
if (readn(FD(evsel, cpu, thread), &count, nv * sizeof(u64)) < 0)
return -errno;
- compute_deltas(evsel, cpu, &count);
+ perf_evsel__compute_deltas(evsel, cpu, &count);
if (scale) {
if (count.run == 0)
}
}
- compute_deltas(evsel, -1, aggr);
+ perf_evsel__compute_deltas(evsel, -1, aggr);
evsel->counts->scaled = 0;
if (scale) {
struct perf_evlist;
struct record_opts;
+void perf_evsel__compute_deltas(struct perf_evsel *evsel, int cpu,
+ struct perf_counts_values *count);
+
int perf_evsel__object_config(size_t object_size,
int (*init)(struct perf_evsel *evsel),
void (*fini)(struct perf_evsel *evsel));