Lines Matching refs:thread
35 struct thread *thread; member
38 DECLARE_RC_STRUCT(thread) { in DECLARE_RC_STRUCT() argument
79 struct thread *thread__new(pid_t pid, pid_t tid);
80 int thread__init_maps(struct thread *thread, struct machine *machine);
81 void thread__delete(struct thread *thread);
85 struct thread *thread__get(struct thread *thread);
86 void thread__put(struct thread *thread);
88 static inline void __thread__zput(struct thread **thread) in __thread__zput() argument
90 thread__put(*thread); in __thread__zput()
91 *thread = NULL; in __thread__zput()
94 #define thread__zput(thread) __thread__zput(&thread) argument
96 struct namespaces *thread__namespaces(struct thread *thread);
97 int thread__set_namespaces(struct thread *thread, u64 timestamp,
100 int __thread__set_comm(struct thread *thread, const char *comm, u64 timestamp,
102 static inline int thread__set_comm(struct thread *thread, const char *comm, in thread__set_comm() argument
105 return __thread__set_comm(thread, comm, timestamp, false); in thread__set_comm()
108 int thread__set_comm_from_proc(struct thread *thread);
110 int thread__comm_len(struct thread *thread);
111 struct comm *thread__comm(struct thread *thread);
112 struct comm *thread__exec_comm(struct thread *thread);
113 const char *thread__comm_str(struct thread *thread);
114 int thread__insert_map(struct thread *thread, struct map *map);
115 int thread__fork(struct thread *thread, struct thread *parent, u64 timestamp, bool do_maps_clone);
116 size_t thread__fprintf(struct thread *thread, FILE *fp);
118 struct thread *thread__main_thread(struct machine *machine, struct thread *thread);
120 struct map *thread__find_map(struct thread *thread, u8 cpumode, u64 addr,
122 struct map *thread__find_map_fb(struct thread *thread, u8 cpumode, u64 addr,
125 struct symbol *thread__find_symbol(struct thread *thread, u8 cpumode,
127 struct symbol *thread__find_symbol_fb(struct thread *thread, u8 cpumode,
130 void thread__find_cpumode_addr_location(struct thread *thread, u64 addr,
133 int thread__memcpy(struct thread *thread, struct machine *machine,
136 static inline struct maps *thread__maps(struct thread *thread) in thread__maps() argument
138 return RC_CHK_ACCESS(thread)->maps; in thread__maps()
141 static inline void thread__set_maps(struct thread *thread, struct maps *maps) in thread__set_maps() argument
143 RC_CHK_ACCESS(thread)->maps = maps; in thread__set_maps()
146 static inline pid_t thread__pid(const struct thread *thread) in thread__pid() argument
148 return RC_CHK_ACCESS(thread)->pid_; in thread__pid()
151 static inline void thread__set_pid(struct thread *thread, pid_t pid_) in thread__set_pid() argument
153 RC_CHK_ACCESS(thread)->pid_ = pid_; in thread__set_pid()
156 static inline pid_t thread__tid(const struct thread *thread) in thread__tid() argument
158 return RC_CHK_ACCESS(thread)->tid; in thread__tid()
161 static inline void thread__set_tid(struct thread *thread, pid_t tid) in thread__set_tid() argument
163 RC_CHK_ACCESS(thread)->tid = tid; in thread__set_tid()
166 static inline pid_t thread__ppid(const struct thread *thread) in thread__ppid() argument
168 return RC_CHK_ACCESS(thread)->ppid; in thread__ppid()
171 static inline void thread__set_ppid(struct thread *thread, pid_t ppid) in thread__set_ppid() argument
173 RC_CHK_ACCESS(thread)->ppid = ppid; in thread__set_ppid()
176 static inline int thread__cpu(const struct thread *thread) in thread__cpu() argument
178 return RC_CHK_ACCESS(thread)->cpu; in thread__cpu()
181 static inline void thread__set_cpu(struct thread *thread, int cpu) in thread__set_cpu() argument
183 RC_CHK_ACCESS(thread)->cpu = cpu; in thread__set_cpu()
186 static inline int thread__guest_cpu(const struct thread *thread) in thread__guest_cpu() argument
188 return RC_CHK_ACCESS(thread)->guest_cpu; in thread__guest_cpu()
191 static inline void thread__set_guest_cpu(struct thread *thread, int guest_cpu) in thread__set_guest_cpu() argument
193 RC_CHK_ACCESS(thread)->guest_cpu = guest_cpu; in thread__set_guest_cpu()
196 static inline refcount_t *thread__refcnt(struct thread *thread) in thread__refcnt() argument
198 return &RC_CHK_ACCESS(thread)->refcnt; in thread__refcnt()
201 static inline void thread__set_exited(struct thread *thread, bool exited) in thread__set_exited() argument
203 RC_CHK_ACCESS(thread)->exited = exited; in thread__set_exited()
206 static inline bool thread__comm_set(const struct thread *thread) in thread__comm_set() argument
208 return RC_CHK_ACCESS(thread)->comm_set; in thread__comm_set()
211 static inline void thread__set_comm_set(struct thread *thread, bool set) in thread__set_comm_set() argument
213 RC_CHK_ACCESS(thread)->comm_set = set; in thread__set_comm_set()
216 static inline int thread__var_comm_len(const struct thread *thread) in thread__var_comm_len() argument
218 return RC_CHK_ACCESS(thread)->comm_len; in thread__var_comm_len()
221 static inline void thread__set_comm_len(struct thread *thread, int len) in thread__set_comm_len() argument
223 RC_CHK_ACCESS(thread)->comm_len = len; in thread__set_comm_len()
226 static inline struct list_head *thread__namespaces_list(struct thread *thread) in thread__namespaces_list() argument
228 return &RC_CHK_ACCESS(thread)->namespaces_list; in thread__namespaces_list()
231 static inline int thread__namespaces_list_empty(const struct thread *thread) in thread__namespaces_list_empty() argument
233 return list_empty(&RC_CHK_ACCESS(thread)->namespaces_list); in thread__namespaces_list_empty()
236 static inline struct rw_semaphore *thread__namespaces_lock(struct thread *thread) in thread__namespaces_lock() argument
238 return &RC_CHK_ACCESS(thread)->namespaces_lock; in thread__namespaces_lock()
241 static inline struct list_head *thread__comm_list(struct thread *thread) in thread__comm_list() argument
243 return &RC_CHK_ACCESS(thread)->comm_list; in thread__comm_list()
246 static inline struct rw_semaphore *thread__comm_lock(struct thread *thread) in thread__comm_lock() argument
248 return &RC_CHK_ACCESS(thread)->comm_lock; in thread__comm_lock()
251 static inline u64 thread__db_id(const struct thread *thread) in thread__db_id() argument
253 return RC_CHK_ACCESS(thread)->db_id; in thread__db_id()
256 static inline void thread__set_db_id(struct thread *thread, u64 db_id) in thread__set_db_id() argument
258 RC_CHK_ACCESS(thread)->db_id = db_id; in thread__set_db_id()
261 static inline void *thread__priv(struct thread *thread) in thread__priv() argument
263 return RC_CHK_ACCESS(thread)->priv; in thread__priv()
266 static inline void thread__set_priv(struct thread *thread, void *p) in thread__set_priv() argument
268 RC_CHK_ACCESS(thread)->priv = p; in thread__set_priv()
271 static inline struct thread_stack *thread__ts(struct thread *thread) in thread__ts() argument
273 return RC_CHK_ACCESS(thread)->ts; in thread__ts()
276 static inline void thread__set_ts(struct thread *thread, struct thread_stack *ts) in thread__set_ts() argument
278 RC_CHK_ACCESS(thread)->ts = ts; in thread__set_ts()
281 static inline struct nsinfo *thread__nsinfo(struct thread *thread) in thread__nsinfo() argument
283 return RC_CHK_ACCESS(thread)->nsinfo; in thread__nsinfo()
286 static inline struct srccode_state *thread__srccode_state(struct thread *thread) in thread__srccode_state() argument
288 return &RC_CHK_ACCESS(thread)->srccode_state; in thread__srccode_state()
291 static inline bool thread__filter(const struct thread *thread) in thread__filter() argument
293 return RC_CHK_ACCESS(thread)->filter; in thread__filter()
296 static inline void thread__set_filter(struct thread *thread, bool filter) in thread__set_filter() argument
298 RC_CHK_ACCESS(thread)->filter = filter; in thread__set_filter()
301 static inline int thread__filter_entry_depth(const struct thread *thread) in thread__filter_entry_depth() argument
303 return RC_CHK_ACCESS(thread)->filter_entry_depth; in thread__filter_entry_depth()
306 static inline void thread__set_filter_entry_depth(struct thread *thread, int depth) in thread__set_filter_entry_depth() argument
308 RC_CHK_ACCESS(thread)->filter_entry_depth = depth; in thread__set_filter_entry_depth()
311 static inline bool thread__lbr_stitch_enable(const struct thread *thread) in thread__lbr_stitch_enable() argument
313 return RC_CHK_ACCESS(thread)->lbr_stitch_enable; in thread__lbr_stitch_enable()
316 static inline void thread__set_lbr_stitch_enable(struct thread *thread, bool en) in thread__set_lbr_stitch_enable() argument
318 RC_CHK_ACCESS(thread)->lbr_stitch_enable = en; in thread__set_lbr_stitch_enable()
321 static inline struct lbr_stitch *thread__lbr_stitch(struct thread *thread) in thread__lbr_stitch() argument
323 return RC_CHK_ACCESS(thread)->lbr_stitch; in thread__lbr_stitch()
326 static inline void thread__set_lbr_stitch(struct thread *thread, struct lbr_stitch *lbrs) in thread__set_lbr_stitch() argument
328 RC_CHK_ACCESS(thread)->lbr_stitch = lbrs; in thread__set_lbr_stitch()
331 static inline bool thread__is_filtered(struct thread *thread) in thread__is_filtered() argument
334 !strlist__has_entry(symbol_conf.comm_list, thread__comm_str(thread))) { in thread__is_filtered()
339 !intlist__has_entry(symbol_conf.pid_list, thread__pid(thread))) { in thread__is_filtered()
344 !intlist__has_entry(symbol_conf.tid_list, thread__tid(thread))) { in thread__is_filtered()
351 void thread__free_stitch_list(struct thread *thread);
353 void thread__resolve(struct thread *thread, struct addr_location *al,