cache.h 733 B

12345678910111213141516171819202122232425262728293031
  1. #ifndef __PERF_CACHE_H
  2. #define __PERF_CACHE_H
  3. #include "strbuf.h"
  4. #include <subcmd/pager.h>
  5. #include "../ui/ui.h"
  6. #include <linux/string.h>
  7. #define CMD_EXEC_PATH "--exec-path"
  8. #define CMD_DEBUGFS_DIR "--debugfs-dir="
  9. #define EXEC_PATH_ENVIRONMENT "PERF_EXEC_PATH"
  10. #define PERF_DEBUGFS_ENVIRONMENT "PERF_DEBUGFS_DIR"
  11. #define PERF_TRACEFS_ENVIRONMENT "PERF_TRACEFS_DIR"
  12. #define PERF_PAGER_ENVIRONMENT "PERF_PAGER"
  13. char *alias_lookup(const char *alias);
  14. int split_cmdline(char *cmdline, const char ***argv);
  15. #define alloc_nr(x) (((x)+16)*3/2)
  16. static inline int is_absolute_path(const char *path)
  17. {
  18. return path[0] == '/';
  19. }
  20. char *mkpath(const char *fmt, ...) __attribute__((format (printf, 1, 2)));
  21. #endif /* __PERF_CACHE_H */