Lines Matching refs:thread
244 struct thread *thread; member
1190 static struct thread_trace *thread__trace(struct thread *thread, FILE *fp) in thread__trace() argument
1194 if (thread == NULL) in thread__trace()
1197 if (thread__priv(thread) == NULL) in thread__trace()
1198 thread__set_priv(thread, thread_trace__new()); in thread__trace()
1200 if (thread__priv(thread) == NULL) in thread__trace()
1203 ttrace = thread__priv(thread); in thread__trace()
1229 struct thread *current;
1261 static int trace__set_fd_pathname(struct thread *thread, int fd, const char *pathname) in trace__set_fd_pathname() argument
1263 struct thread_trace *ttrace = thread__priv(thread); in trace__set_fd_pathname()
1287 static int thread__read_fd_path(struct thread *thread, int fd) in thread__read_fd_path() argument
1293 if (thread->pid_ == thread->tid) { in thread__read_fd_path()
1295 "/proc/%d/fd/%d", thread->pid_, fd); in thread__read_fd_path()
1298 "/proc/%d/task/%d/fd/%d", thread->pid_, thread->tid, fd); in thread__read_fd_path()
1310 return trace__set_fd_pathname(thread, fd, pathname); in thread__read_fd_path()
1313 static const char *thread__fd_path(struct thread *thread, int fd, in thread__fd_path() argument
1316 struct thread_trace *ttrace = thread__priv(thread); in thread__fd_path()
1328 if (thread__read_fd_path(thread, fd)) in thread__fd_path()
1340 const char *path = thread__fd_path(arg->thread, fd, arg->trace); in syscall_arg__scnprintf_fd()
1353 struct thread_trace *ttrace = thread__priv(arg->thread); in syscall_arg__scnprintf_close_fd()
1382 static size_t trace__fprintf_entry_head(struct trace *trace, struct thread *thread, in trace__fprintf_entry_head() argument
1390 printed += fprintf(fp, "%.14s/", thread__comm_str(thread)); in trace__fprintf_entry_head()
1391 printed += fprintf(fp, "%d ", thread->tid); in trace__fprintf_entry_head()
1545 struct thread *thread) in syscall__scnprintf_args() argument
1558 .thread = thread, in syscall__scnprintf_args()
1714 struct thread *thread; in trace__sys_enter() local
1725 thread = machine__findnew_thread(trace->host, sample->pid, sample->tid); in trace__sys_enter()
1726 ttrace = thread__trace(thread, trace->output); in trace__sys_enter()
1746 args, trace, thread); in trace__sys_enter()
1750 trace__fprintf_entry_head(trace, thread, 1, sample->time, trace->output); in trace__sys_enter()
1756 if (trace->current != thread) { in trace__sys_enter()
1758 trace->current = thread__get(thread); in trace__sys_enter()
1770 struct thread *thread; in trace__sys_exit() local
1781 thread = machine__findnew_thread(trace->host, sample->pid, sample->tid); in trace__sys_exit()
1782 ttrace = thread__trace(thread, trace->output); in trace__sys_exit()
1792 trace__set_fd_pathname(thread, ret, trace->last_vfs_getname); in trace__sys_exit()
1809 trace__fprintf_entry_head(trace, thread, duration, sample->time, trace->output); in trace__sys_exit()
1856 struct thread *thread = machine__findnew_thread(trace->host, in trace__sched_stat_runtime() local
1859 struct thread_trace *ttrace = thread__trace(thread, trace->output); in trace__sched_stat_runtime()
1922 struct thread *thread; in trace__pgfault() local
1928 thread = machine__findnew_thread(trace->host, sample->pid, sample->tid); in trace__pgfault()
1929 ttrace = thread__trace(thread, trace->output); in trace__pgfault()
1941 thread__find_addr_location(thread, cpumode, MAP__FUNCTION, in trace__pgfault()
1944 trace__fprintf_entry_head(trace, thread, 0, sample->time, trace->output); in trace__pgfault()
1954 thread__find_addr_location(thread, cpumode, MAP__VARIABLE, in trace__pgfault()
1958 thread__find_addr_location(thread, cpumode, in trace__pgfault()
2504 static int trace__fprintf_one_thread(struct thread *thread, void *priv) in trace__fprintf_one_thread() argument
2510 struct thread_trace *ttrace = thread__priv(thread); in trace__fprintf_one_thread()
2518 printed += fprintf(fp, " %s (%d), ", thread__comm_str(thread), thread->tid); in trace__fprintf_one_thread()