Home
last modified time | relevance | path

Searched refs:threads (Results 101 - 125 of 539) sorted by relevance

12345678910>>...22

/kernel/linux/linux-5.10/kernel/kcsan/
H A Dkcsan-test.c39 static struct task_struct **threads; /* Lists of threads. */ variable
959 * Each test case is run with different numbers of threads. Until KUnit supports
960 * passing arguments for each test case, we encode #threads in the test case
962 * preference to separate test name and #threads.]
1004 /* Get number of threads encoded in test name. */
1087 if (WARN_ON(threads)) in test_init()
1110 pr_warn("%s: limiting number of threads to %d\n", in test_init()
1116 threads = kcalloc(nthreads + 1, sizeof(struct task_struct *), in test_init()
1118 if (WARN_ON(!threads)) in test_init()
[all...]
/kernel/linux/linux-5.10/tools/perf/util/
H A Dsynthetic-events.h54 int perf_event__synthesize_thread_map2(struct perf_tool *tool, struct perf_thread_map *threads, perf_event__handler_t process, struct machine *machine);
55 int perf_event__synthesize_thread_map(struct perf_tool *tool, struct perf_thread_map *threads, perf_event__handler_t process, struct machine *machine, bool mmap_data);
66 struct target *target, struct perf_thread_map *threads,
70 struct perf_thread_map *threads, bool data_mmap,
H A Dmachine.h33 struct threads { struct
50 struct threads threads[THREADS__TABLE_SIZE]; member
65 static inline struct threads *machine__threads(struct machine *machine, pid_t tid) in machine__threads()
68 return &machine->threads[(unsigned int)tid % THREADS__TABLE_SIZE]; in machine__threads()
H A Dpython.c640 struct perf_thread_map *threads; member
653 pthreads->threads = thread_map__new(pid, tid, uid); in pyrf_thread_map__init()
654 if (pthreads->threads == NULL) in pyrf_thread_map__init()
661 perf_thread_map__put(pthreads->threads); in pyrf_thread_map__delete()
669 return pthreads->threads->nr; in pyrf_thread_map__length()
676 if (i >= pthreads->threads->nr) in pyrf_thread_map__item()
679 return Py_BuildValue("i", pthreads->threads->map[i]); in pyrf_thread_map__item()
832 struct perf_thread_map *threads = NULL; in pyrf_evsel__open() local
835 static char *kwlist[] = { "cpus", "threads", "group", "inherit", NULL }; in pyrf_evsel__open()
842 threads in pyrf_evsel__open()
901 struct perf_thread_map *threads; pyrf_evlist__init() local
[all...]
/kernel/linux/linux-6.6/tools/perf/util/
H A Dsynthetic-events.h70 int perf_event__synthesize_thread_map2(struct perf_tool *tool, struct perf_thread_map *threads, perf_event__handler_t process, struct machine *machine);
71 int perf_event__synthesize_thread_map(struct perf_tool *tool, struct perf_thread_map *threads, perf_event__handler_t process, struct machine *machine, bool needs_mmap, bool mmap_data);
82 struct target *target, struct perf_thread_map *threads,
86 struct perf_thread_map *threads, bool needs_mmap, bool data_mmap,
H A Dmachine.h34 struct threads { struct
52 struct threads threads[THREADS__TABLE_SIZE]; member
73 static inline struct threads *machine__threads(struct machine *machine, pid_t tid) in machine__threads()
76 return &machine->threads[(unsigned int)tid % THREADS__TABLE_SIZE]; in machine__threads()
H A Dpython.c743 struct perf_thread_map *threads; member
756 pthreads->threads = thread_map__new(pid, tid, uid); in pyrf_thread_map__init()
757 if (pthreads->threads == NULL) in pyrf_thread_map__init()
764 perf_thread_map__put(pthreads->threads); in pyrf_thread_map__delete()
772 return perf_thread_map__nr(pthreads->threads); in pyrf_thread_map__length()
779 if (i >= perf_thread_map__nr(pthreads->threads)) in pyrf_thread_map__item()
782 return Py_BuildValue("i", perf_thread_map__pid(pthreads->threads, i)); in pyrf_thread_map__item()
935 struct perf_thread_map *threads = NULL; in pyrf_evsel__open() local
938 static char *kwlist[] = { "cpus", "threads", "group", "inherit", NULL }; in pyrf_evsel__open()
945 threads in pyrf_evsel__open()
1004 struct perf_thread_map *threads; pyrf_evlist__init() local
[all...]
H A Devsel.c375 evsel->core.threads = perf_thread_map__get(orig->core.threads); in evsel__clone()
1476 perf_thread_map__put(evsel->core.threads); in evsel__exit()
1714 struct perf_thread_map *threads, in evsel__ignore_missing_thread()
1717 pid_t ignore_pid = perf_thread_map__pid(threads, thread); in evsel__ignore_missing_thread()
1722 /* The system wide setup does not work with threads. */ in evsel__ignore_missing_thread()
1731 if (threads->nr == 1) in evsel__ignore_missing_thread()
1736 * because thread_map__remove() will decrease threads->nr. in evsel__ignore_missing_thread()
1738 if (update_fds(evsel, nr_cpus, cpu_map_idx, threads->nr, thread)) in evsel__ignore_missing_thread()
1741 if (thread_map__remove(threads, threa in evsel__ignore_missing_thread()
1712 evsel__ignore_missing_thread(struct evsel *evsel, int nr_cpus, int cpu_map_idx, struct perf_thread_map *threads, int thread, int err) evsel__ignore_missing_thread() argument
1792 __evsel__prepare_open(struct evsel *evsel, struct perf_cpu_map *cpus, struct perf_thread_map *threads) __evsel__prepare_open() argument
1867 evsel__prepare_open(struct evsel *evsel, struct perf_cpu_map *cpus, struct perf_thread_map *threads) evsel__prepare_open() argument
2019 evsel__open_cpu(struct evsel *evsel, struct perf_cpu_map *cpus, struct perf_thread_map *threads, int start_cpu_map_idx, int end_cpu_map_idx) evsel__open_cpu() argument
2171 evsel__open(struct evsel *evsel, struct perf_cpu_map *cpus, struct perf_thread_map *threads) evsel__open() argument
2191 evsel__open_per_thread(struct evsel *evsel, struct perf_thread_map *threads) evsel__open_per_thread() argument
3087 struct perf_thread_map *threads = evsel->core.threads; evsel__store_ids() local
[all...]
/kernel/linux/linux-5.10/tools/testing/selftests/powerpc/signal/
H A Dsigfuz.c46 #define THREADS 16 /* Number of threads */
252 pthread_t *threads; in signal_fuzzer() local
254 threads = malloc(nthread * sizeof(pthread_t)); in signal_fuzzer()
257 rc = pthread_create(&threads[t], NULL, sigfuz_test, in signal_fuzzer()
264 rc = pthread_join(threads[t], NULL); in signal_fuzzer()
269 free(threads); in signal_fuzzer()
284 printf("\t-t\t Amount of threads. (Default = %d)\n", THREADS); in show_help()
/kernel/linux/linux-6.6/tools/testing/selftests/kvm/x86_64/
H A Dhyperv_ipi.c247 pthread_t threads[2]; in main() local
276 r = pthread_create(&threads[0], NULL, vcpu_thread, vcpu[1]); in main()
279 r = pthread_create(&threads[1], NULL, vcpu_thread, vcpu[2]); in main()
306 cancel_join_vcpu_thread(threads[0], vcpu[1]); in main()
307 cancel_join_vcpu_thread(threads[1], vcpu[2]); in main()
H A Dxapic_ipi_test.c400 pthread_t threads[2]; in main() local
435 r = pthread_create(&threads[0], NULL, vcpu_thread, &params[0]); in main()
454 r = pthread_create(&threads[1], NULL, vcpu_thread, &params[1]); in main()
467 * Cancel threads and wait for them to stop. in main()
469 cancel_join_vcpu_thread(threads[0], params[0].vcpu); in main()
470 cancel_join_vcpu_thread(threads[1], params[1].vcpu); in main()
/kernel/linux/linux-6.6/tools/testing/selftests/bpf/map_tests/
H A Dmap_percpu_stats.c174 pthread_t threads[N_THREADS]; in upsert_elements() local
178 for (i = 0; i < ARRAY_SIZE(threads); i++) { in upsert_elements()
179 ret = pthread_create(&i[threads], NULL, patch_map_thread, opts); in upsert_elements()
183 for (i = 0; i < ARRAY_SIZE(threads); i++) { in upsert_elements()
184 ret = pthread_join(i[threads], NULL); in upsert_elements()
286 * N_THREADS threads. Check values, then delete all elements and check in __test()
/kernel/linux/linux-6.6/tools/testing/selftests/powerpc/signal/
H A Dsigfuz.c46 #define THREADS 16 /* Number of threads */
252 pthread_t *threads; in signal_fuzzer() local
254 threads = malloc(nthread * sizeof(pthread_t)); in signal_fuzzer()
257 rc = pthread_create(&threads[t], NULL, sigfuz_test, in signal_fuzzer()
264 rc = pthread_join(threads[t], NULL); in signal_fuzzer()
269 free(threads); in signal_fuzzer()
284 printf("\t-t\t Amount of threads. (Default = %d)\n", THREADS); in show_help()
/kernel/linux/linux-5.10/drivers/acpi/acpica/
H A Ddbexec.c437 * Allow any handlers in separate threads to complete. in acpi_db_execute()
518 * Prevent acpi_gbl_db_method_info from being modified by multiple threads in acpi_db_method_thread()
533 if (info->threads && (info->num_created < info->num_threads)) { in acpi_db_method_thread()
534 info->threads[info->num_created++] = acpi_os_get_thread_id(); in acpi_db_method_thread()
709 * PARAMETERS: num_threads_arg - Number of threads to create
715 * DESCRIPTION: Create threads to execute method(s)
745 * the created threads with the main thread. in acpi_db_create_execution_threads()
757 * between the created threads. in acpi_db_create_execution_threads()
762 "synchronization between the created threads, %s\n", in acpi_db_create_execution_threads()
782 /* Array to store IDs of threads */ in acpi_db_create_execution_threads()
[all...]
/kernel/linux/linux-5.10/tools/perf/tests/
H A Dcode-reading.c568 struct perf_thread_map *threads = NULL; in do_test_code_reading() local
610 threads = thread_map__new_by_tid(pid); in do_test_code_reading()
611 if (!threads) { in do_test_code_reading()
616 ret = perf_event__synthesize_thread_map(NULL, threads, in do_test_code_reading()
644 perf_evlist__set_maps(&evlist->core, cpus, threads); in do_test_code_reading()
667 * Both cpus and threads are now owned by evlist in do_test_code_reading()
672 perf_thread_map__get(threads); in do_test_code_reading()
722 perf_thread_map__put(threads); in do_test_code_reading()
/kernel/linux/linux-6.6/drivers/acpi/acpica/
H A Ddbexec.c437 * Allow any handlers in separate threads to complete. in acpi_db_execute()
518 * Prevent acpi_gbl_db_method_info from being modified by multiple threads in acpi_db_method_thread()
533 if (info->threads && (info->num_created < info->num_threads)) { in acpi_db_method_thread()
534 info->threads[info->num_created++] = acpi_os_get_thread_id(); in acpi_db_method_thread()
709 * PARAMETERS: num_threads_arg - Number of threads to create
715 * DESCRIPTION: Create threads to execute method(s)
745 * the created threads with the main thread. in acpi_db_create_execution_threads()
757 * between the created threads. in acpi_db_create_execution_threads()
762 "synchronization between the created threads, %s\n", in acpi_db_create_execution_threads()
782 /* Array to store IDs of threads */ in acpi_db_create_execution_threads()
[all...]
/kernel/linux/linux-6.6/tools/perf/tests/
H A Dcode-reading.c569 struct perf_thread_map *threads = NULL; in do_test_code_reading() local
613 threads = thread_map__new_by_tid(pid); in do_test_code_reading()
614 if (!threads) { in do_test_code_reading()
619 ret = perf_event__synthesize_thread_map(NULL, threads, in do_test_code_reading()
648 perf_evlist__set_maps(&evlist->core, cpus, threads); in do_test_code_reading()
671 * Both cpus and threads are now owned by evlist in do_test_code_reading()
676 perf_thread_map__get(threads); in do_test_code_reading()
723 perf_thread_map__put(threads); in do_test_code_reading()
/kernel/linux/linux-6.6/tools/lib/perf/
H A Devsel.c114 struct perf_thread_map *threads) in perf_evsel__open()
131 if (threads == NULL) { in perf_evsel__open()
140 threads = empty_thread_map; in perf_evsel__open()
144 perf_evsel__alloc_fd(evsel, perf_cpu_map__nr(cpus), threads->nr) < 0) in perf_evsel__open()
148 for (thread = 0; thread < threads->nr; thread++) { in perf_evsel__open()
162 threads->map[thread].pid, in perf_evsel__open()
505 return evsel->threads; in perf_evsel__threads()
113 perf_evsel__open(struct perf_evsel *evsel, struct perf_cpu_map *cpus, struct perf_thread_map *threads) perf_evsel__open() argument
/kernel/linux/linux-5.10/tools/perf/python/
H A Dtracepoint.py20 threads = perf.thread_map(-1)
22 evlist = perf.evlist(cpus, threads)
/kernel/linux/linux-6.6/tools/perf/python/
H A Dtracepoint.py20 threads = perf.thread_map(-1)
22 evlist = perf.evlist(cpus, threads)
/kernel/linux/linux-6.6/tools/testing/selftests/timers/
H A Dposix_timers.c207 * Test that all running threads _eventually_ receive CLOCK_PROCESS_CPUTIME_ID
215 pthread_t threads[nthreads]; in check_timer_distribution() local
226 remain = nthreads + 1; /* worker threads + this thread */ in check_timer_distribution()
240 if (pthread_create(&threads[i], NULL, distribution_thread, NULL)) { in check_timer_distribution()
246 /* Wait for all threads to receive the signal. */ in check_timer_distribution()
250 if (pthread_join(threads[i], NULL)) { in check_timer_distribution()
268 printf("based timers if other threads run on the CPU...\n"); in main()
/kernel/linux/linux-6.6/drivers/gpu/drm/i915/gt/
H A Dselftest_hangcheck.c968 struct active_engine *threads; in __igt_reset_engines() local
989 threads = kmalloc_array(I915_NUM_ENGINES, sizeof(*threads), GFP_KERNEL); in __igt_reset_engines()
990 if (!threads) in __igt_reset_engines()
1012 memset(threads, 0, sizeof(*threads) * I915_NUM_ENGINES); in __igt_reset_engines()
1016 threads[tmp].resets = in __igt_reset_engines()
1025 threads[tmp].engine = other; in __igt_reset_engines()
1026 threads[tmp].flags = flags; in __igt_reset_engines()
1037 threads[tm in __igt_reset_engines()
[all...]
/kernel/linux/linux-5.10/arch/powerpc/include/asm/
H A Dcputhreads.h10 * Mapping of threads to cores
13 * threads per core and the same number for each core in the system
14 * (though it would work if some processors had less threads as long
38 * @threads: a cpumask of online threads
46 static inline cpumask_t cpu_thread_mask_to_cores(const struct cpumask *threads) in cpu_thread_mask_to_cores() argument
54 if (cpumask_intersects(threads, &tmp)) { in cpu_thread_mask_to_cores()
/kernel/linux/build/test/unittest/rtg/
H A Drtg_test.cpp670 vector<int> threads; in HWTEST_F() local
680 threads.push_back(pid[i]); in HWTEST_F()
684 ret = AddThreadsToRtg(threads, grpId, NORMAL_TASK); in HWTEST_F()
692 * @tc.desc: Verify rtg multiple add function with out of limit threads.
699 vector<int> threads; in HWTEST_F() local
709 threads.push_back(pid[i]); in HWTEST_F()
713 ret = AddThreadsToRtg(threads, grpId, NORMAL_TASK); in HWTEST_F()
/kernel/linux/linux-5.10/tools/testing/radix-tree/
H A Didr-test.c551 pthread_t threads[20]; in ida_thread_tests() local
554 for (i = 0; i < ARRAY_SIZE(threads); i++) in ida_thread_tests()
555 if (pthread_create(&threads[i], NULL, ida_random_fn, NULL)) { in ida_thread_tests()
561 pthread_join(threads[i], NULL); in ida_thread_tests()
563 for (i = 0; i < ARRAY_SIZE(threads); i++) in ida_thread_tests()
564 if (pthread_create(&threads[i], NULL, ida_leak_fn, &ida)) { in ida_thread_tests()
570 pthread_join(threads[i], NULL); in ida_thread_tests()

Completed in 21 milliseconds

12345678910>>...22