User Guide

Contents

Annotate Parallel Sites and Tasks

You add
annotations
into your program to mark the tasks and parallel sites. The annotations are one-line macro uses or function calls that have no effect on the behavior of your program.
Annotations allow you to mark your tentative decisions about your program's task structure before you modify the program to use parallel execution. Annotations are used by the
Intel® Advisor
Suitability and Dependencies tools.
After you decide on the parallel site(s) and task(s), add the annotations into your source code.
To simplify adding
Intel® Advisor
annotations:
  • When using the
    Microsoft Visual Studio*
    code editor, you can use the Annotation Wizard.
  • With any editor, use the annotation assistant in the
    Survey Report
    window,
    Survey Source
    window, or the
    No Data
    message to copy example annotation code and build settings.
Code examples throughout this group of topics illustrate the use of these annotations.
As you use
Intel® Advisor
to investigate possible code regions for adding parallel execution, you will find some areas are not feasible. Adding a comment to explain why that site (or task) was not chosen may help later. For example, with C/C++ code:
... // Investigated the following function call as a parallel task and dismissed // June 2014. Need to first re-write the function to improve parallel // performance and fix the data race. // // ANNOTATE_TASK_BEGIN(func1); . . .

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.