Skip to content

Latest commit

 

History

History
45 lines (30 loc) · 2.06 KB

qpar-auto-parallelizer.md

File metadata and controls

45 lines (30 loc) · 2.06 KB
description title ms.date f1_keywords ms.assetid
Learn more about: /Qpar (Auto-Parallelizer)
/Qpar (Auto-Parallelizer)
11/04/2016
VC.Project.VCCLCompilerTool.EnableParallelCodeGeneration
33ecf49d-c0d5-4f34-bce3-84ff03f38918

/Qpar (Auto-Parallelizer)

Enables the Auto-Parallelizer feature of the compiler to automatically parallelize loops in your code.

Syntax

/Qpar

Remarks

When the compiler automatically parallelizes loops in code, it spreads computation across multiple processor cores. A loop is parallelized only if the compiler determines that it is legal to do so and that parallelization would improve performance.

The #pragma loop() directives are available to help the optimizer parallelize specific loops. For more information, see loop.

For information about how to enable output messages for the auto-parallelizer, see /Qpar-report (Auto-Parallelizer Reporting Level).

To set the /Qpar compiler option in Visual Studio

  1. Open the project's Property Pages dialog box. For details, see Set C++ compiler and build properties in Visual Studio.

  2. Select the Configuration Properties > C/C++ > Command Line property page.

  3. In the Additional Options box, enter /Qpar.

To set the /Qpar compiler option programmatically

  • Use the code example in xref:Microsoft.VisualStudio.VCProjectEngine.VCCLCompilerTool.AdditionalOptions%2A.

See also

/Q Options (Low-Level Operations)
/Qpar-report (Auto-Parallelizer Reporting Level)
MSVC Compiler Options
MSVC Compiler Command-Line Syntax
#pragma loop()
Native code vectorization in Visual Studio