Lines Matching refs:td
56 struct thread_data *td = __tdata; in worker_thread() local
61 if (!td->nr) { in worker_thread()
62 ret = read(td->pipe_read, &m, sizeof(int)); in worker_thread()
64 ret = write(td->pipe_write, &m, sizeof(int)); in worker_thread()
67 ret = write(td->pipe_write, &m, sizeof(int)); in worker_thread()
69 ret = read(td->pipe_read, &m, sizeof(int)); in worker_thread()
79 struct thread_data threads[2], *td; in bench_sched_pipe() local
102 td = threads + t; in bench_sched_pipe()
104 td->nr = t; in bench_sched_pipe()
107 td->pipe_read = pipe_1[0]; in bench_sched_pipe()
108 td->pipe_write = pipe_2[1]; in bench_sched_pipe()
110 td->pipe_write = pipe_1[1]; in bench_sched_pipe()
111 td->pipe_read = pipe_2[0]; in bench_sched_pipe()
119 td = threads + t; in bench_sched_pipe()
121 ret = pthread_create(&td->pthread, NULL, worker_thread, td); in bench_sched_pipe()
126 td = threads + t; in bench_sched_pipe()
128 ret = pthread_join(td->pthread, NULL); in bench_sched_pipe()