Integrating the Intel Compiler and Microsoft Visual Studio Software

Overview

If the Intel® compiler will be used to compile PSCAD projects, then a compatible version of Microsoft® Visual Studio is also required to be installed, and “integrated” with the Intel compiler. If integration is not established, a PSCAD project will not build, and the Build messages will include some sort of error, for example that Visual Studio software is not detected.

Integration normally occurs in the following manners:

  • When installing the Intel compiler, and the Microsoft Visual Studio Premier Partner Edition is also selected for installation, then both software are installed and integrated, or

    Note - The Visual Studio Premier Partner Edition comes bundled with the licensed edition of Intel compiler as of Intel v19.2 and older. No edition of Visual Studio comes with the trial edition of Intel nor with the licensed edition of Intel v19.3 and newer.

  • When installing the Intel compiler, and if a suitable version of the Microsoft Visual Studio software is already installed, then integration can be selected.

Applicability

This article is applicable for Intel v19.0 and older, as preliminary testing has revealed that Integration is not required for Intel v19.1 and newer.

Detecting Integration

To detect whether Integration is present, the following steps may be followed:

  • Download and launch the newest version of Fortran Medic ustility as per steps a-d of this article.

  • The utility will display information on your setup. Scroll down to “Intel Fortran Integration” to view the Intel Fortran / Visual Studio integration.

For example, the following data from a test machine shows that Intel 17 is integrated with Visual Studio 2015 (v14):
Fortran Medic - Intel 17 is integrated wtih VS 2015.png (29 KB)

For example, the following data from a test machine shows that no integration was detected:

Fortran Medic - Intel 17 is NOT integrated wtih VS 2015.png (39 KB)

How to Add Integration if Both Intel and Visual Studio Software are Already Installed

If both Intel compiler and Visual Studio software are installed, but integration is not established, there are two ways to resolve this. Note - both methods will require Windows Administrator privileges.

  • Method 1 - Re-Installation of the Intel Compiler Software:

    -Re-install the Intel compiler (Licensed Edition, or Trial Edition).

    -During the installation, select the option to "customize" the installation when prompted, so that you can ensure the Visual Studio software is selected for integration.

  • Method 2 - Manually force integration of the Intel Compiler and Visual Studio software using the fortran_compilers configuration file

    -Open a Windows browser to display the PSCAD vXX program files folder. For example, for v4.6.3, the filepath would normally be the following:

       C:\Program Files (x86)\PSCAD46

    -From the above path, open the fortran_compilers.xml file, in Notepad:Compiler file - how to display it.png (29 KB)

- In the fortran_compilers.xml file, supported compilers will be listed. All 32-bit editions will be listed first, followed by the 64-bit editions, as shown below:

Compiler file - all contents.png (75 KB)

- Perform the following to force-integrate the software:

Locate the row for the compiler to be integrated.

For example, for Intel 19.1 (64-bits), the selection below (version=“18.0,later”) shows the corresponding row:

Compiler file - IVF19.1 64-bits.png (33 KB)

In the corresponding row, find the batch arguments text:

batch_args="intel64"

Modify the batch arguments text to include the version of Fisual Studio. The format is to add VSXXXX and a space after the first quotation mark.

For example, to integrate Visual Studio 2017 with Intel 19.1, change the text to:

batch_args="VS2017 intel64"

Save and close the fortran_compilers.xml file.

After making the above change, log out and log back in on your machine, then test your setup by trying to run the simple example.

If there are no errors, then your setup is ready for your own cases. If you have any compiling issues, please refer to this article for troubleshooting tips or instructions for contacting the MHI support desk for assistance.

 

Back