mem-events.h 970 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #ifndef __PERF_MEM_EVENTS_H
  2. #define __PERF_MEM_EVENTS_H
  3. #include <stdbool.h>
  4. struct perf_mem_event {
  5. bool record;
  6. bool supported;
  7. const char *tag;
  8. const char *name;
  9. const char *sysfs_name;
  10. };
  11. enum {
  12. PERF_MEM_EVENTS__LOAD,
  13. PERF_MEM_EVENTS__STORE,
  14. PERF_MEM_EVENTS__MAX,
  15. };
  16. extern struct perf_mem_event perf_mem_events[PERF_MEM_EVENTS__MAX];
  17. extern unsigned int perf_mem_events__loads_ldlat;
  18. int perf_mem_events__parse(const char *str);
  19. int perf_mem_events__init(void);
  20. char *perf_mem_events__name(int i);
  21. struct mem_info;
  22. int perf_mem__tlb_scnprintf(char *out, size_t sz, struct mem_info *mem_info);
  23. int perf_mem__lvl_scnprintf(char *out, size_t sz, struct mem_info *mem_info);
  24. int perf_mem__snp_scnprintf(char *out, size_t sz, struct mem_info *mem_info);
  25. int perf_mem__lck_scnprintf(char *out, size_t sz, struct mem_info *mem_info);
  26. int perf_script__meminfo_scnprintf(char *bf, size_t size, struct mem_info *mem_info);
  27. #endif /* __PERF_MEM_EVENTS_H */