Lines Matching refs:td
57 struct thread_data *td = __tdata; in worker_thread() local
62 if (!td->nr) { in worker_thread()
63 ret = read(td->pipe_read, &m, sizeof(int)); in worker_thread()
65 ret = write(td->pipe_write, &m, sizeof(int)); in worker_thread()
68 ret = write(td->pipe_write, &m, sizeof(int)); in worker_thread()
70 ret = read(td->pipe_read, &m, sizeof(int)); in worker_thread()
80 struct thread_data threads[2], *td; in bench_sched_pipe() local
103 td = threads + t; in bench_sched_pipe()
105 td->nr = t; in bench_sched_pipe()
108 td->pipe_read = pipe_1[0]; in bench_sched_pipe()
109 td->pipe_write = pipe_2[1]; in bench_sched_pipe()
111 td->pipe_write = pipe_1[1]; in bench_sched_pipe()
112 td->pipe_read = pipe_2[0]; in bench_sched_pipe()
120 td = threads + t; in bench_sched_pipe()
122 ret = pthread_create(&td->pthread, NULL, worker_thread, td); in bench_sched_pipe()
127 td = threads + t; in bench_sched_pipe()
129 ret = pthread_join(td->pthread, NULL); in bench_sched_pipe()