Home
last modified time | relevance | path

Searched refs:unit (Results 1 – 25 of 49) sorted by relevance

12

/tools/perf/util/
Dunits.c36 unsigned long convert_unit(unsigned long value, char *unit) in convert_unit() argument
38 *unit = ' '; in convert_unit()
42 *unit = 'K'; in convert_unit()
47 *unit = 'M'; in convert_unit()
52 *unit = 'G'; in convert_unit()
60 char unit[4] = "BKMG"; in unit_number__scnprintf() local
68 return scnprintf(buf, size, "%" PRIu64 "%c", n, unit[i]); in unit_number__scnprintf()
Dstat-display.c174 const char *unit, double val) in print_metric_std() argument
183 if (unit == NULL || fmt == NULL) { in print_metric_std()
196 fprintf(out, " %-*s", METRIC_LEN - n - 1, unit); in print_metric_std()
215 const char *fmt, const char *unit, double val) in print_metric_csv() argument
221 if (unit == NULL || fmt == NULL) { in print_metric_csv()
230 fprintf(out, "%s%s%s%s", config->csv_sep, vals, config->csv_sep, skip_spaces(unit)); in print_metric_csv()
235 static bool valid_only_metric(const char *unit) in valid_only_metric() argument
237 if (!unit) in valid_only_metric()
239 if (strstr(unit, "/sec") || in valid_only_metric()
240 strstr(unit, "CPUs utilized")) in valid_only_metric()
[all …]
Dpmu.c187 sret = read(fd, alias->unit, UNIT_MAX_LEN); in perf_pmu__parse_unit()
193 if (alias->unit[sret - 1] == '\n') in perf_pmu__parse_unit()
194 alias->unit[sret - 1] = '\0'; in perf_pmu__parse_unit()
196 alias->unit[sret] = '\0'; in perf_pmu__parse_unit()
201 alias->unit[0] = '\0'; in perf_pmu__parse_unit()
273 memcpy(old->unit, newalias->unit, sizeof(old->unit)); in perf_pmu_update_alias()
311 char *unit, char *perpkg, in __perf_pmu__new_alias() argument
328 alias->unit[0] = '\0'; in __perf_pmu__new_alias()
378 if (unit) { in __perf_pmu__new_alias()
379 if (perf_pmu__convert_scale(unit, &unit, &alias->scale) < 0) in __perf_pmu__new_alias()
[all …]
Dunits.h15 unsigned long convert_unit(unsigned long value, char *unit);
Dpmu.h50 const char *unit; member
68 char unit[UNIT_MAX_LEN+1]; member
Dstat-shadow.c868 char *unit; in generic_metric() local
873 &unit, &scale) >= 0) { in generic_metric()
878 "%s %s_%d", unit, metric_name, runtime); in generic_metric()
881 "%s %s", unit, metric_name); in generic_metric()
1169 char unit = 'M'; in perf_stat__print_shadow_stats() local
1178 unit = 'K'; in perf_stat__print_shadow_stats()
1180 snprintf(unit_buf, sizeof(unit_buf), "%c/sec", unit); in perf_stat__print_shadow_stats()
Dstat.h189 void *ctx, const char *color, const char *unit,
Devsel.c243 evsel->unit = ""; in evsel__init()
281 static const char *unit = "msec"; in evsel__new_idx() local
283 evsel->unit = unit; in evsel__new_idx()
413 evsel->unit = orig->unit; in evsel__clone()
1255 if (evsel->core.own_cpus || evsel->unit) in evsel__config()
Devsel.h65 const char *unit; member
/tools/power/cpupower/utils/
Dcpufreq-set.c65 const struct freq_units *unit; in string_to_frequency() local
83 for (unit = def_units; unit->str_unit; unit++) { in string_to_frequency()
85 scan[i] && tolower(scan[i]) == unit->str_unit[i]; in string_to_frequency()
91 power = unit->power_of_ten; in string_to_frequency()
/tools/testing/selftests/memfd/
Drun_hugetlbfs_test.sh16 while read name size unit; do
36 while read name size unit; do
/tools/perf/pmu-events/
Dpmu-events.h20 const char *unit; member
Djevents.c62 char *unit; member
368 if (je->unit) in print_events_table_entry()
369 fprintf(outfp, "\t.unit = \"%s\",\n", je->unit); in print_events_table_entry()
396 char *unit; member
426 op(unit); \
626 addfield(map, &je.unit, "", "", val); in json_events()
693 free(je.unit); in json_events()
/tools/testing/selftests/vm/
Drun_vmtests12 while read name size unit; do
44 while read name size unit; do
/tools/perf/tests/
Dpmu-events.c202 if (!is_same(table->unit, te->unit)) { in test_pmu_event_table()
204 table->name, table->unit, in test_pmu_event_table()
205 te->unit); in test_pmu_event_table()
Devent_update.c102 evsel->unit = strdup("KRAVA"); in test__event_update()
/tools/testing/selftests/arm64/signal/
DREADME7 - Tests are built around a common main compilation unit: such shared main
17 to run each test unit in its own standalone process, so as to start each
/tools/io_uring/
DREADME24 and contains a number of unit tests as well for testing io_uring. It also
/tools/testing/selftests/tc-testing/
DREADME1 tdc - Linux Traffic Control (tc) unit testing suite
5 tdc is a Python script to load tc unit tests from a separate JSON file and
21 unit tests. See the config file in this directory for minimum required
123 Linux TC unit tests
/tools/testing/selftests/ftrace/
DREADME34 These are to be unit tests.
/tools/perf/Documentation/
Dperf-ftrace.txt67 be a number with appended unit character - B/K/M/G.
/tools/testing/selftests/net/forwarding/
Dlib.sh705 for unit in bps Kbps Mbps Gbps; do
713 echo "$speed${unit}"
/tools/perf/
Dbuiltin-report.c449 char unit; in hists__fprintf_nr_sample_events() local
484 nr_samples = convert_unit(nr_samples, &unit); in hists__fprintf_nr_sample_events()
485 ret = fprintf(fp, "# Samples: %lu%c", nr_samples, unit); in hists__fprintf_nr_sample_events()
/tools/perf/ui/browsers/
Dhists.c3415 char bf[256], unit; in perf_evsel_menu__write() local
3433 nr_events = convert_unit(nr_events, &unit); in perf_evsel_menu__write()
3435 unit, unit == ' ' ? "" : " ", ev_name); in perf_evsel_menu__write()
3443 nr_events = convert_unit(nr_events, &unit); in perf_evsel_menu__write()
3445 nr_events, unit, unit == ' ' ? "" : " "); in perf_evsel_menu__write()
/tools/perf/scripts/python/
Dexported-sql-viewer.py1659 unit = self.Unit()
1660 if unit >= 1000000000:
1661 unit = int(unit / 1000000000)
1663 elif unit >= 1000000:
1664 unit = int(unit / 1000000)
1666 elif unit >= 1000:
1667 unit = int(unit / 1000)
1670 unit = int(unit)
1672 return " = " + str(unit) + " " + us

12