Home | History | Annotate | Download | only in latencytop

Lines Matching defs:pid

45 static struct latency_entry *read_process_stats(struct latency_entry *list, int erase, int pid);
46 static struct latency_entry *read_thread_stats(struct latency_entry *list, int erase, int pid, int tid, int fatal);
72 int pid, tid;
78 pid = tid = 0;
106 pid = atoi(argv[++i]);
122 if (tid && !pid) {
146 if (pid) {
148 e = read_thread_stats(e, erase, pid, tid, 1);
150 e = read_process_stats(e, erase, pid);
158 if (pid) {
160 printf("Latencies for thread %d in process %d:\n", tid, pid);
162 printf("Latencies for process %d:\n", pid);
202 static struct latency_entry *read_process_stats(struct latency_entry *list, int erase, int pid) {
209 sprintf(dirname, "/proc/%d/task", pid);
212 fprintf(stderr, "Could not open task dir for process %d.\n", pid);
224 e = read_thread_stats(e, erase, pid, tid, 0);
232 static struct latency_entry *read_thread_stats(struct latency_entry *list, int erase, int pid, int tid, int fatal) {
237 sprintf(filename, THREAD_STATS_FILE_FORMAT, pid, tid);
421 fprintf(stderr, "Usage: %s [ -d delay ] [ -n iterations ] [ -p pid [ -t tid ] ] [ -h ]\n"
424 " -p pid Process to monitor (default is all).\n"