Home
last modified time | relevance | path

Searched refs:thread_attr (Results 1 – 9 of 9) sorted by relevance

/Linux-v5.10/tools/perf/bench/
Dfutex-wake-parallel.c94 static void wakeup_threads(struct thread_data *td, pthread_attr_t thread_attr) in wakeup_threads() argument
98 pthread_attr_setdetachstate(&thread_attr, PTHREAD_CREATE_JOINABLE); in wakeup_threads()
109 if (pthread_create(&td[i].worker, &thread_attr, in wakeup_threads()
141 static void block_threads(pthread_t *w, pthread_attr_t thread_attr, in block_threads() argument
154 if (pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset)) in block_threads()
157 if (pthread_create(&w[i], &thread_attr, blocked_workerfn, NULL)) in block_threads()
226 pthread_attr_t thread_attr; in bench_futex_wake_parallel() local
276 pthread_attr_init(&thread_attr); in bench_futex_wake_parallel()
287 block_threads(blocked_worker, thread_attr, cpu); in bench_futex_wake_parallel()
299 wakeup_threads(waking_worker, thread_attr); in bench_futex_wake_parallel()
[all …]
Dfutex-wake.c94 pthread_attr_t thread_attr, struct perf_cpu_map *cpu) in block_threads() argument
106 if (pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset)) in block_threads()
109 if (pthread_create(&w[i], &thread_attr, workerfn, NULL)) in block_threads()
126 pthread_attr_t thread_attr; in bench_futex_wake() local
160 pthread_attr_init(&thread_attr); in bench_futex_wake()
170 block_threads(worker, thread_attr, cpu); in bench_futex_wake()
208 pthread_attr_destroy(&thread_attr); in bench_futex_wake()
Dfutex-requeue.c88 pthread_attr_t thread_attr, struct perf_cpu_map *cpu) in block_threads() argument
100 if (pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset)) in block_threads()
103 if (pthread_create(&w[i], &thread_attr, workerfn, NULL)) in block_threads()
120 pthread_attr_t thread_attr; in bench_futex_requeue() local
155 pthread_attr_init(&thread_attr); in bench_futex_requeue()
165 block_threads(worker, thread_attr, cpu); in bench_futex_requeue()
214 pthread_attr_destroy(&thread_attr); in bench_futex_requeue()
Dfutex-lock-pi.c118 static void create_threads(struct worker *w, pthread_attr_t thread_attr, in create_threads() argument
139 if (pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset)) in create_threads()
142 if (pthread_create(&w[i].thread, &thread_attr, workerfn, &worker[i])) in create_threads()
152 pthread_attr_t thread_attr; in bench_futex_lock_pi() local
187 pthread_attr_init(&thread_attr); in bench_futex_lock_pi()
190 create_threads(worker, thread_attr, cpu); in bench_futex_lock_pi()
191 pthread_attr_destroy(&thread_attr); in bench_futex_lock_pi()
Dfutex-hash.c126 pthread_attr_t thread_attr; in bench_futex_hash() local
164 pthread_attr_init(&thread_attr); in bench_futex_hash()
175 ret = pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset); in bench_futex_hash()
179 ret = pthread_create(&worker[i].thread, &thread_attr, workerfn, in bench_futex_hash()
185 pthread_attr_destroy(&thread_attr); in bench_futex_hash()
Depoll-ctl.c225 pthread_attr_t thread_attr, *attrp = NULL; in do_threads() local
231 pthread_attr_init(&thread_attr); in do_threads()
259 ret = pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset); in do_threads()
263 attrp = &thread_attr; in do_threads()
273 pthread_attr_destroy(&thread_attr); in do_threads()
Depoll-wait.c294 pthread_attr_t thread_attr, *attrp = NULL; in do_threads() local
308 pthread_attr_init(&thread_attr); in do_threads()
348 ret = pthread_attr_setaffinity_np(&thread_attr, sizeof(cpu_set_t), &cpuset); in do_threads()
352 attrp = &thread_attr; in do_threads()
362 pthread_attr_destroy(&thread_attr); in do_threads()
/Linux-v5.10/tools/build/feature/
Dtest-pthread-attr-setaffinity-np.c9 pthread_attr_t thread_attr; in main() local
12 pthread_attr_init(&thread_attr); in main()
15 ret = pthread_attr_setaffinity_np(&thread_attr, sizeof(cs), &cs); in main()
/Linux-v5.10/tools/testing/selftests/mqueue/
Dmq_perf_tests.c714 pthread_attr_t thread_attr; in main() local
726 pthread_attr_init(&thread_attr); in main()
727 pthread_attr_setaffinity_np(&thread_attr, cpu_set_size, in main()
729 if (pthread_create(&cpu_threads[i], &thread_attr, thread_func, in main()
732 pthread_attr_destroy(&thread_attr); in main()