Lines Matching defs:thread_index
233 int thread_index;
297 for (thread_index = 0; thread_index < thread_num; thread_index++) {
299 fd[nr_cpu][counter][thread_index] = sys_perf_event_open(attr,
300 all_tids[thread_index], cpu, group_fd, 0);
302 if (fd[nr_cpu][counter][thread_index] < 0) {
330 fd[nr_cpu][counter][thread_index], strerror(err));
355 if (read(fd[nr_cpu][counter][thread_index], &read_data, sizeof(read_data)) == -1) {
365 assert(fd[nr_cpu][counter][thread_index] >= 0);
366 fcntl(fd[nr_cpu][counter][thread_index], F_SETFL, O_NONBLOCK);
372 group_fd = fd[nr_cpu][counter][thread_index];
374 if (counter || thread_index) {
375 ret = ioctl(fd[nr_cpu][counter][thread_index],
388 PROT_READ|PROT_WRITE, MAP_SHARED, fd[nr_cpu][counter][thread_index], 0);
394 event_array[nr_poll].fd = fd[nr_cpu][counter][thread_index];
400 ret = ioctl(fd[nr_cpu][counter][thread_index],