Lines Matching refs:metrics

1947 } metrics[] = {  variable
2032 metric_cnt = ARRAY_SIZE(metrics); in profile_parse_metrics()
2036 if (is_prefix(argv[0], metrics[i].name)) { in profile_parse_metrics()
2037 if (!metrics[i].selected) in profile_parse_metrics()
2039 metrics[i].selected = true; in profile_parse_metrics()
2082 for (m = 0; m < ARRAY_SIZE(metrics); m++) { in profile_read_values()
2085 if (!metrics[m].selected) in profile_read_values()
2095 metrics[m].val.counter += values[cpu].counter; in profile_read_values()
2096 metrics[m].val.enabled += values[cpu].enabled; in profile_read_values()
2097 metrics[m].val.running += values[cpu].running; in profile_read_values()
2108 for (m = 0; m < ARRAY_SIZE(metrics); m++) { in profile_print_readings_json()
2109 if (!metrics[m].selected) in profile_print_readings_json()
2112 jsonw_string_field(json_wtr, "metric", metrics[m].name); in profile_print_readings_json()
2114 jsonw_lluint_field(json_wtr, "value", metrics[m].val.counter); in profile_print_readings_json()
2115 jsonw_lluint_field(json_wtr, "enabled", metrics[m].val.enabled); in profile_print_readings_json()
2116 jsonw_lluint_field(json_wtr, "running", metrics[m].val.running); in profile_print_readings_json()
2128 for (m = 0; m < ARRAY_SIZE(metrics); m++) { in profile_print_readings_plain()
2129 struct bpf_perf_event_value *val = &metrics[m].val; in profile_print_readings_plain()
2132 if (!metrics[m].selected) in profile_print_readings_plain()
2134 printf("%18llu %-20s", val->counter, metrics[m].name); in profile_print_readings_plain()
2136 r = metrics[m].ratio_metric - 1; in profile_print_readings_plain()
2137 if (r >= 0 && metrics[r].selected && in profile_print_readings_plain()
2138 metrics[r].val.counter > 0) { in profile_print_readings_plain()
2140 val->counter * metrics[m].ratio_mul / in profile_print_readings_plain()
2141 metrics[r].val.counter, in profile_print_readings_plain()
2142 metrics[m].ratio_desc); in profile_print_readings_plain()
2240 pmu_fd = syscall(__NR_perf_event_open, &metrics[mid].attr, in profile_open_perf_event()
2245 cpu, metrics[mid].name); in profile_open_perf_event()
2282 for (m = 0; m < ARRAY_SIZE(metrics); m++) { in profile_open_perf_events()
2283 if (!metrics[m].selected) in profile_open_perf_events()
2288 metrics[m].name, cpu); in profile_open_perf_events()