Visual Studio* IDE: Choose Project and Build Application

Before you start analyzing your application target for hotspots, do the following:

  1. Get software tools.

  2. Choose a project.

  3. Verify optimal compiler/linker options.

  4. Configure target properties.

  5. Build the target in the release mode.

  6. Create a performance baseline.


  • The steps below are provide for Microsoft Visual Studio 2013. They may slightly differ for other versions of Visual Studio.
  • Steps provided in this tutorial are generic and applicable to any application. You may choose to follow the proposed workflow using your own application.

Get Software Tools

You need the following tools to try tutorial steps yourself using the nqueens_fortran sample application:

  • VTune Amplifier, including sample applications

  • .zip file extraction utility

  • Supported Fortran compiler (see Release Notes for more information)

Acquire Intel VTune Amplifier

If you do not already have access to the VTune Amplifier, you can download an evaluation copy from

Install and Set Up VTune Amplifier Sample Applications

  1. Copy the file from the <install-dir>\samples\<locale>\Fortran\ directory to a writable directory or share on your system. The default installation path is C:\Program Files (x86)\IntelSWTools\VTune Amplifier XE <version>\ (on certain systems, instead of Program Files (x86), the directory name is Program Files).
  2. Extract the sample from the .zip file.


  • Samples are non-deterministic. Your screens may vary from the screen captures shown throughout this tutorial.
  • Samples are designed only to illustrate the VTune Amplifier features; they do not represent best practices for creating code.

Choose a Project

Choose a project with the analysis target in the Visual Studio IDE as follows:

  1. From the Visual Studio menu, select File > Open > Project/Solution....

    The Open Project dialog box opens.

  2. In the Open Project dialog box, browse to the location you used to extract the file and select the nqueens_fortran.sln file from the nqueens_fortran\vf9 directory.

    Draft comment:

    The solution is added to Visual Studio IDE and shows up in the Solution Explorer.


    If you are using a recent version of Visual Studio, a message may appear directing you to upgrade the project. Click OK and the project will be automatically upgraded to be compatible with your version of Visual Studio.
  3. In the Solution Explorer, right-click the nqueens_parallel project and select Set as StartUp Project.

    nqueens_parallel appears in bold in the Solution Explorer.


    nqueens_serial project provides a single-threaded version of the sample application. This project is provided for your reference only and not described in this tutorial.

When you choose a project in Visual Studio IDE, the VTune Amplifier automatically creates the config.amplxeproj project file and sets the nqueens_parallel application as an analysis target in the project properties.

Verify Optimal Compiler/Linker Options

Configure Visual Studio project properties to generate the debug information for your application so that the VTune Amplifier can open the source code.

  1. Select the nqueens_parallel project and go to Project > Properties.

    The nqueens_parallel Property Pages dialog box opens.

  2. Select Configuration Properties > General and make sure the selected Configuration (top of the dialog) is Release.

  3. Select Fortran > General pane and specify the Debug Information Format as Full (/debug:full) .

  4. Select Fortran > Optimization pane and set the Optimization to Maximize Speed.

  5. Select Linker > Debugging and set the Generate Debug Info option to Yes (/DEBUG).

Configure Target Properties

  1. Right-click the nqueens_parallel project and select Properties from the context menu.

    The nqueens_parallel Property Pages dialog box opens.

  2. In the nqueens_parallel Property Pages dialog box, select Configuration Properties > Debugging.

  3. In the right pane, specify the Command Arguments as 15.

Build the Target in the Release Mode

Build the target in the Release mode with full optimizations, which is recommended for performance analysis.

  1. Go to the Build > Configuration Manager... dialog box and select the Release mode for your target project.

  2. From the Visual Studio menu, select Build > Build nqueens_parallel.

    The nqueens_parallel.exe application is built with your default Fortran compiler. For this tutorial, Intel Fortran Compiler XE is used.


The build configuration for nqueens_parallel may initially be set to Debug, which is typically used for development. When analyzing performance issues with the VTune Amplifier, you are recommended to use the Release build with normal optimizations. In this way, the VTune Amplifier is able to analyze the realistic performance of your application.

Create a Performance Baseline

Run the application to create a performance baseline that will be used to identify optimization you achieve during performance tuning with the VTune Amplifier.


Before you start the application, minimize the amount of other software running on your computer to get more accurate results.

  1. From the Visual Studio menu, select Debug > Start Without Debugging.

    The nqueens_parallel.exe application starts running.

    Draft comment:

  2. Note the execution time displayed in the window caption. In the example above, the execution time is 12890 milliseconds.


    • Run the application several times, note the execution time for each run, and use the average number. This helps to minimize skewed results due to transient system activity.

    • The screenshots and execution time data provided in this tutorial are created on a system with 4 CPU cores. Your data may vary depending on the number and type of CPU cores on your system.


You chose the target for the Basic Hotspots analysis, set up your environment to enable generating symbol information for your binary files, built the target in the Release mode, and created the performance baseline. Your application is ready for analysis.

Optimization Notice

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804

Para obtener información más completa sobre las optimizaciones del compilador, consulte nuestro Aviso de optimización.