Lines Matching defs:event
3 /* Parse event JSON files */
208 char **event, jsmntok_t *val)
216 addfield(map, event, ",", f->kernel, &newval);
234 pr_err("%s: Unknown MSR in event file %.*s\n", prog,
326 static int print_events_table_entry(void *data, char *name, const char *event,
344 if (event)
345 fprintf(outfp, "\t.event = \"%s\",\n", event);
370 char *event;
397 op(event); \
421 static int save_arch_std_events(void *data __unused, char *name, const char *event,
446 fprintf(outfp, "\t.event = 0,\n");
456 const char *event;
458 { "inst_retired.any", "event=0xc0" },
459 { "inst_retired.any_p", "event=0xc0" },
460 { "cpu_clk_unhalted.ref", "event=0x0,umask=0x03" },
461 { "cpu_clk_unhalted.thread", "event=0x3c" },
462 { "cpu_clk_unhalted.thread_any", "event=0x3c,any=1" },
469 static const char *real_event(const char *name, char *event)
478 return fixed[i].event;
479 return event;
483 try_fixup(const char *fn, char *arch_std, char **event, char **desc,
488 /* try to find matching event from arch standard values */
493 if (!eventcode && es->event) {
495 free(*event);
496 *event = NULL;
508 /* Call func with each event in the json file */
510 int (*func)(void *data, char *name, const char *event, char *desc,
533 char *event = NULL, *desc = NULL, *name = NULL;
564 if (match_field(map, field, nz, &event, val)) {
642 "(Precise event)", NULL);
644 snprintf(buf, sizeof buf, "event=%#llx", eventcode);
645 addfield(map, &event, ",", buf, NULL);
651 addfield(map, &event, ",", filter, NULL);
653 addfield(map, &event, ",", msr->pname, msrval);
659 * An arch standard event is referenced, so try to
662 err = try_fixup(fn, arch_std, &event, &desc, &name,
669 err = func(data, name, real_event(name, event), desc, long_desc,
672 free(event);
1071 * PMU event tables (see struct pmu_events_map).
1073 * Write out the PMU events tables and the mapping table to pmu-event.c.
1108 /* If architecture does not have any event lists, bail out */
1110 pr_info("%s: Arch %s has no PMU event lists\n", prog, arch);