Find Time Regions of Low Concurrency and Their Cause
Run the trace collector.
In the Execution Trace Views tab, inspect the node concurrency histogram for regions in red, which indicate low concurrency.
Zoom in to a red region to inspect the data at a higher resolution and provide a better idea as to how concurrency varies over time.
Select a point in the chart where the concurrency is low to highlight the relevant node(s). Hover the mouse over the highlighted node to identify the node name.
Because the analysis tool does not have built-in symbol resolution, the determination of the C++ class of the body executed by a node must be explicitly encoded into the application. Explicit encoding affects the Name and/or object_name fields in the Node Properties tab. For example:
tbb::flow::graph g; . . . tbb::flow::source_node<int> s_node (g, source_node_body(), false); #if TBB_PREVIEW_FLOW_GRAPH_TRACE s_node.set_name(“My Source Node”); #endif
This coding enables node annotation with the specified string during trace collection, and the annotation appears when you hover the mouse over the node.
The set_name functions are only available when the TBB_PREVIEW_FLOW_GRAPH_TRACE macro is defined at compile-time.
Did you find the information on this page useful?