Home
last modified time | relevance | path

Searched refs:ncpus (Results 1 – 25 of 32) sorted by relevance

12

/external/ltp/testcases/kernel/syscalls/sched_setaffinity/
Dsched_setaffinity01.c57 static long ncpus; variable
98 ncpus = tst_ncpus_max(); in setup()
101 mask = CPU_ALLOC(ncpus); in setup()
104 ncpus); in setup()
105 mask_size = CPU_ALLOC_SIZE(ncpus); in setup()
110 emask = CPU_ALLOC(ncpus + 1); in setup()
113 ncpus + 1); in setup()
114 emask_size = CPU_ALLOC_SIZE(ncpus + 1); in setup()
116 CPU_SET_S(ncpus, emask_size, emask); in setup()
Dsched_setaffinity.h36 #define CPU_ALLOC(ncpus) malloc(sizeof(cpu_set_t)); \ argument
37 if (ncpus > CPU_SETSIZE) { \
39 "Your libc does not support masks with %ld cpus", ncpus); \
/external/linux-kselftest/tools/testing/selftests/rcutorture/bin/
Dcpus2use.sh25 ncpus=`grep '^processor' /proc/cpuinfo | wc -l`
27 awk -v ncpus=$ncpus '{ print ncpus * ($7 + $NF) / 100 }'`
28 awk -v ncpus=$ncpus -v idlecpus=$idlecpus < /dev/null '
Dkvm-build.sh62 ncpus=`cpus2use.sh`
63 make O=$builddir -j$ncpus $TORTURE_KMAKE_ARG > $builddir/Make.out 2>&1
Dkvm.sh220 awk < $T/cfgcpu.sort > $T/cfgcpu.pack -v ncpus=$cpus '
309 -v ncpus=$cpus \
/external/ltp/testcases/kernel/controllers/cpuset/cpuset_lib/
Dcpuinfo.c25 int ncpus; variable
38 if (!ncpus) { in get_cpu_baseinfo()
39 ncpus = get_ncpus(); in get_cpu_baseinfo()
40 if (ncpus <= 0) in get_cpu_baseinfo()
50 cpus = malloc(sizeof(*cpus) * ncpus); in get_cpu_baseinfo()
53 memset(cpus, 0, sizeof(*cpus) * ncpus); in get_cpu_baseinfo()
68 if (data >= ncpus) { in get_cpu_baseinfo()
103 for (i = 0; i < ncpus; i++) { in online_cpumask()
225 if (ci < 0 || ci >= ncpus) { in get_sched_domains()
256 if (!ncpus) { in getcpuinfo()
[all …]
Dlibcpuset.c1205 int ncpus = cpuset_cpus_nbits(); in rebuild_map() local
1209 for (cpu = 0; cpu < (unsigned int)ncpus; cpu++) in rebuild_map()
1223 if (cpu >= (unsigned int)ncpus in rebuild_map()
1248 int ncpus = cpuset_cpus_nbits(); in load_map() local
1252 if ((cpunodemap.map = calloc(ncpus, sizeof(int))) == NULL) in load_map()
1257 for (cpu = 0; cpu < (unsigned int)ncpus; cpu++) in load_map()
1262 if (cpu >= (unsigned int)ncpus || mem >= (unsigned int)nmems) in load_map()
1284 int ncpus = cpuset_cpus_nbits(); in store_map() local
1293 for (cpu = 0; cpu < (unsigned int)ncpus; cpu++) { in store_map()
1362 int ncpus = cpuset_cpus_nbits(); in cpuset_localcpus() local
[all …]
Dcpuinfo.h13 extern int ncpus;
/external/ltp/testcases/kernel/mem/cpuset/
Dcpuset01.c63 static long ncpus; variable
76 ncpus = count_cpu(); in main()
112 exit(mem_hog_cpuset(ncpus > 1 ? ncpus : 1)); in testcpuset()
228 int ncpus = 0; in count_cpu() local
230 while (path_exist(PATH_SYS_SYSTEM "/cpu/cpu%d", ncpus)) in count_cpu()
231 ncpus++; in count_cpu()
233 return ncpus; in count_cpu()
/external/swiftshader/third_party/LLVM/utils/lit/lit/
DUtil.py11 ncpus = os.sysconf("SC_NPROCESSORS_ONLN")
12 if isinstance(ncpus, int) and ncpus > 0:
13 return ncpus
18 ncpus = int(os.environ["NUMBER_OF_PROCESSORS"])
19 if ncpus > 0:
20 return ncpus
/external/ltp/lib/
Dtst_cpu.c27 long ncpus = -1; in tst_ncpus() local
29 ncpus = SAFE_SYSCONF(NULL, _SC_NPROCESSORS_ONLN); in tst_ncpus()
33 return ncpus; in tst_ncpus()
/external/llvm/utils/lit/lit/
Dutil.py34 ncpus = os.sysconf("SC_NPROCESSORS_ONLN")
35 if isinstance(ncpus, int) and ncpus > 0:
36 return ncpus
41 ncpus = int(os.environ["NUMBER_OF_PROCESSORS"])
42 if ncpus > 0:
45 return min(ncpus, 32)
/external/autotest/client/tests/monotonic_time/src/
Dtime_test.c234 int ncpus; in run_test() local
256 ncpus = count_cpus(cpus); in run_test()
258 if (nthreads != ncpus) { in run_test()
260 ncpus, nthreads); in run_test()
270 test->name, ncpus, duration); in run_test()
272 INFO("running %s test on %d cpus", test->name, ncpus); in run_test()
/external/blktrace/
Dblktrace.c96 int fd, idx, ncpus; member
218 int fd, ncpus; member
277 static int ncpus; variable
866 hdr.max_cpus = ncpus; in net_send_header()
1009 cl_fds = calloc(ncpus, sizeof(*cl_fds)); in open_client_connections()
1010 for (cpu = 0; cpu < ncpus; cpu++) { in open_client_connections()
1029 for (cpu = 0, fdp = cl_fds; cpu < ncpus; cpu++, fdp++) { in close_client_connections()
1052 dpp->ncpus = ncpus; in setup_buts()
1056 dpp->stats = calloc(dpp->ncpus, sizeof(*dpp->stats)); in setup_buts()
1057 memset(dpp->stats, 0, dpp->ncpus * sizeof(*dpp->stats)); in setup_buts()
[all …]
Dblkparse.c64 int ncpus; member
324 int ncpus = pdi->ncpus; in resize_cpu_info() local
338 new_start = (char *)cpus + (ncpus * sizeof(struct per_cpu_info)); in resize_cpu_info()
339 new_space = (new_count - ncpus) * sizeof(struct per_cpu_info); in resize_cpu_info()
342 pdi->ncpus = new_count; in resize_cpu_info()
345 for (new_count = 0; new_count < pdi->ncpus; new_count++) { in resize_cpu_info()
361 if (cpu >= pdi->ncpus) in get_cpu_info()
490 for (cpu = 0; cpu < pdi->ncpus; cpu++) { in collect_pdi_skips()
1786 for (pci = pdi->cpus, j = 0; j < pdi->ncpus; j++, pci++) { in show_device_and_cpu_stats()
/external/strace/xlat/
Dgen.sh292 local ncpus="$(getconf _NPROCESSORS_ONLN)"
293 [ "${ncpus}" -ge 1 ] ||
294 ncpus=1
305 if [ ${jobs} -ge ${ncpus} ]; then
/external/ltp/testcases/kernel/syscalls/brk/
Dbrk01.c152 int ncpus; in setup() local
173 if ((ncpus = sysconf(_SC_NPROCESSORS_ONLN)) == -1) in setup()
187 max_size = max_size / (2 * ncpus); in setup()
/external/blktrace/btreplay/
Dbtreplay.c145 static int ncpus = 0; // Number of CPUs in the system variable
516 for (ncpus = 0; ncpus < CPU_SETSIZE && CPU_ISSET(ncpus, &cpus); ncpus++) in get_ncpus()
518 if (ncpus == 0) { in get_ncpus()
532 assert(0 <= tip->cpu && tip->cpu < ncpus); in pin_to_cpu()
547 for (i = 0; i < ncpus; i++) in pin_to_cpu()
863 assert(0 <= cpu && cpu < ncpus); in add_input_file()
1471 if (cpus_to_use <= 0 || cpus_to_use > ncpus) { in handle_args()
1474 cpus_to_use, ncpus); in handle_args()
1566 cpus_to_use = ncpus; in handle_args()
/external/clang/utils/analyzer/
DSATestBuild.py69 ncpus = os.sysconf("SC_NPROCESSORS_ONLN")
70 if isinstance(ncpus, int) and ncpus > 0:
71 return ncpus
76 ncpus = int(os.environ["NUMBER_OF_PROCESSORS"])
77 if ncpus > 0:
78 return ncpus
/external/lisa/libs/utils/analysis/
Dresidency_analysis.py140 for cpunr in range(0, self.ncpus):
170 self.ncpus = self._trace.ftrace._cpus # How many total cpus
172 logging.info("TOTAL number of CPUs: {}".format(self.ncpus))
178 for cpunr in range(0, self.ncpus):
/external/autotest/client/profilers/cpistat/
Dcpistat30 ncpus = os.sysconf('SC_NPROCESSORS_ONLN') variable
31 cpus = range(0, ncpus)
/external/lisa/tools/analysis/
Druntime.py125 ncpus = systrace_obj.sched_switch.data_frame["__cpu"].max() + 1 variable
126 print 'cpus found: {}\n'.format(ncpus)
131 testtime = (endtime - starttime) * ncpus # for 4 cpus
/external/ltp/tools/apicmds/
DMakefile30 res resm ncpus ncpus_conf ncpus_max \
/external/ltp/testcases/kernel/controllers/cpuset/cpuset_load_balance_test/
Dcpuset_sched_domains_check.c118 for (i = 0; i < ncpus; i++) { in check_sched_domains()
/external/ltp/testcases/kernel/mem/lib/
Dmem.c696 int ncpus = 0; in gather_node_cpus() local
702 while (path_exist(PATH_SYS_SYSTEM "/cpu/cpu%d", ncpus)) in gather_node_cpus()
703 ncpus++; in gather_node_cpus()
705 for (i = 0; i < ncpus; i++) { in gather_node_cpus()

12