Intel® Advisor User Guide

ID 766448
Date 3/31/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

select

Select loops (by file and line number, ID, or criteria) for deeper analysis.

GUI Equivalent

To select individual loops/functions: Vectorization and Code Insights > Survey & Roofline >

To select loops/functions with markup strategy for Offload Modeling: Offload Modeling > Analysis Workflow > Dependencies > Markup type

Syntax

--select=<string>

Arguments

<string> is a comma-separated list of file name and line number, loop ID, and/or criteria in the [(r|recursive):]<id>|<file>:<line>|<criteria>[,<id>|<file>:<line>|<criteria>,..] format. Add r: (or recursive:) prefix to select all loops in call trees starting from heads selected by criteria, source location or ID. <criteria> can be one of the following:

Criteria

Description

scalar

Include scalar serial loops.

total-time>N

Include loops above N% of total CPU time.

has-source

Exclude loops without source location.

has-issue

Include loops with Vector Dependence Prevent Vectorization or Possible Inefficient Memory Access Pattern issue.

loop-height=N

Include loops at a specific hierarchical position. 0 = Innermost loops.

markup=name

Select loops using a pre-defined mark-up algorithm. Supported algorithms are:

  • gpu_generic - Select loops executed on a GPU.

  • omp - Select OpenMP* loops.

  • icpx -fsycl - Select SYCL loops.

  • ocl - Select OpenCL™ loops.

  • daal - Select Intel® oneAPI Data Analytics Library loops.

  • tbb - Select Intel® oneAPI Threading Building Blocks loops.

Default

No default argument

Actions Modified

collect

mark-up-loops

NOTE:
With the --collect=projection action, the select option accepts only loop/function IDs and source locations (in the <file-name>:<line> format).

Usage

Use + to combine criteria with AND logic. For example, use --select=scalar+has-source to select all scalar loops that have source location.

NOTE:
Selecting loops of interest can decrease collection overhead.

Do not confuse the mark-up-loops action with the mark-up-list action option. The mark-up-loops action coupled with the select action option enables a GUI checkbox; therefore loop selection persists beyond the duration of the mark-up-loops action and applies to downstream analyses, such as Dependencies and Memory Access Patterns analyses. The collect action coupled with the mark-up-list action option simulates enabling a GUI checkbox; therefore loop selection persists only for the duration of the collect action.

Example

  1. Run a Survey analysis to identify loops of interest.

  2. Select those loops for deeper analysis.

advisor --collect=survey --project-dir=./advi_results -- ./myApplication
advisor --mark-up-loops --select=foo.cpp:34,bar.cpp:192 --project-dir=./advi_results -- ./myApplication

See Also