Execute workloads[info.thread_id] first, then call the feeder to get the index of the next workload to run. * * Will run workloads until the feeder reaches the end of its range. * * @param[in] workloads The array of workloads * @param[in,out] feeder The feeder indicating which workload to execute next. * @param[in] info Threading and CPU info. */
| 83 | * @param[in] info Threading and CPU info. |
| 84 | */ |
| 85 | void process_workloads(std::vector<IScheduler::Workload> &workloads, ThreadFeeder &feeder, const ThreadInfo &info) |
| 86 | { |
| 87 | unsigned int workload_index = info.thread_id; |
| 88 | do |
| 89 | { |
| 90 | ARM_COMPUTE_ERROR_ON(workload_index >= workloads.size()); |
| 91 | workloads[workload_index](info); |
| 92 | } while (feeder.get_next(workload_index)); |
| 93 | } |
| 94 | |
| 95 | /** Set thread affinity. Pin current thread to a particular core |
| 96 | * |
no test coverage detected