Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 #ifndef __PERF_THREAD_MAP_H
0003 #define __PERF_THREAD_MAP_H
0004 
0005 #include <sys/types.h>
0006 #include <stdio.h>
0007 #include <linux/refcount.h>
0008 #include <internal/threadmap.h>
0009 #include <perf/threadmap.h>
0010 
0011 struct perf_record_thread_map;
0012 
0013 struct perf_thread_map *thread_map__new_dummy(void);
0014 struct perf_thread_map *thread_map__new_by_pid(pid_t pid);
0015 struct perf_thread_map *thread_map__new_by_tid(pid_t tid);
0016 struct perf_thread_map *thread_map__new_by_uid(uid_t uid);
0017 struct perf_thread_map *thread_map__new_all_cpus(void);
0018 struct perf_thread_map *thread_map__new(pid_t pid, pid_t tid, uid_t uid);
0019 struct perf_thread_map *thread_map__new_event(struct perf_record_thread_map *event);
0020 
0021 struct perf_thread_map *thread_map__new_str(const char *pid,
0022         const char *tid, uid_t uid, bool all_threads);
0023 
0024 struct perf_thread_map *thread_map__new_by_tid_str(const char *tid_str);
0025 
0026 size_t thread_map__fprintf(struct perf_thread_map *threads, FILE *fp);
0027 
0028 void thread_map__read_comms(struct perf_thread_map *threads);
0029 bool thread_map__has(struct perf_thread_map *threads, pid_t pid);
0030 int thread_map__remove(struct perf_thread_map *threads, int idx);
0031 #endif  /* __PERF_THREAD_MAP_H */