MCPcopy Create free account
hub / github.com/ARM-software/ComputeLibrary / measurements

Method measurements

tests/framework/instruments/SchedulerTimer.cpp:257–290  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

255
256template <bool output_timestamps>
257Instrument::MeasurementsMap SchedulerClock<output_timestamps>::measurements() const
258{
259 MeasurementsMap measurements;
260 unsigned int kernel_number = 0;
261 for (auto kernel : _kernels)
262 {
263 std::string name = kernel.prefix + kernel.name + " #" + support::cpp11::to_string(kernel_number++);
264 if (output_timestamps)
265 {
266 ARM_COMPUTE_ERROR_ON(kernel.measurements.size() != 2);
267 for (auto const &m : kernel.measurements)
268 {
269 if (m.first.find("[start]") != std::string::npos)
270 {
271 measurements.emplace("[start]" + name, m.second);
272 }
273 else if (m.first.find("[end]") != std::string::npos)
274 {
275 measurements.emplace("[end]" + name, m.second);
276 }
277 else
278 {
279 ARM_COMPUTE_ERROR("Measurement not handled");
280 }
281 }
282 }
283 else
284 {
285 measurements.emplace(name, kernel.measurements.begin()->second);
286 }
287 }
288
289 return measurements;
290}
291
292template <bool output_timestamps>
293std::string SchedulerClock<output_timestamps>::instrument_header() const

Callers 3

scheduleMethod · 0.45
schedule_opMethod · 0.45
run_tagged_workloadsMethod · 0.45

Calls 4

findMethod · 0.80
to_stringFunction · 0.50
sizeMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected