Intel releases oneAPI Toolkit, free, Fortran 2018

Today, Intel released its oneAPI Toolkit. While there’s a lot in this related to “accelerator” programming, it includes the next version of the Intel Fortran compiler, which now (claims to) support all of Fortran 2018! Even better, it’s now free for everyone, if you don’t mind “community support”. Paid support is still available and if you currently have paid support for Parallel Studio XE, that carries over.

There are two Fortran compilers in this offering. The “Classic” compiler, ifort, is the Fortran 2018 compiler and it works very well. Then there is ifx, a new compiler with an LLVM-based backend. This one is still “beta” and is much shakier.

You will need to install the “Base Toolkit” and then the “HPC Toolkit” to get Fortran. Start at Intel® oneAPI Toolkits

35 Likes

See here how to use it at a CI or in Ubuntu thanks to @awvwgk:

4 Likes

This is great news, and just in time for retirement. For some reason Intel would never give me a free license for my hobby open-source development work that I do on the side which I could use at home. And I’m loath to pay the serious money they were asking for a compiler which I find to be kind of flaky and very slow to fix.

6 Likes

I have been using the oneAPI compilers over a few months now in CI testing and I’m really happy with the way Intel took with the oneAPI toolkits. They are even supported as dep and rpm distribution which makes it super easy to get started by just using apt/yum/dnf to install the Intel Fortran compiler locally or in a CI environment.

Unfortunately, they took down the list with the single apt/yum/dnf packages, so you only see the bundled software kits on their homepage. If you plan to use the compiler in a CI workflow, checking for the individual packages and installing them separately will save you a lot of bandwidth.

4 Likes

Fantastic. Does this also apply to Intel Fortran Compiler for Windows? Or is Windows still a separate issue? I see that Windows is an option in the download list. That would be great as it means there is finally a good easy way of building Fortran libraries by all users, free, on Windows, without recourse to WSL or MINGW,… It would also enable Fortran CI and testing on Windows.

1 Like

Windows, Linux, Mac - all free. I have been told by one of my former colleagues that the Base oneAPI toolkit is not strictly necessary for Fortran. The installer may complain and may even (on Windows) tell you that Visual Studio isn’t installed, but she says it works. I haven’t tested that yet.

4 Likes

I hope this a sustainable business model and the Fortran team can remain strong and grow …

2 Likes

There is really no correlation between software price and funding for a software team, at least at hardware vendors. Prices range from zero to “what the market will bear”. At both DEC and Intel, battles raged about software pricing. At DEC it was particularly problematic as systems salespeople would routinely heavily discount or “throw in” developer tools along with a hardware sale. Intel doesn’t sell systems directly (not counting things like NUCs, which I adore). Developer tools are viewed as a way of making the hardware look better. I once was told that Intel compilers are worth “one bin” of processor speed, which is quite valuable overall.

Intel already has a lot of software it provides for free, and there were many who thought compilers should be. You might shed a tear for resellers, who will now sell less of these (Intel is still selling support contracts), but I think the volumes are low enough that nobody cares.

If you want to support the compiler team, buy lots of systems with Intel CPUs! :laughing:

6 Likes

I’ve wondered for years what performance improvements might be hiding behind the price of the intel compilers :slight_smile: I downloaded these compilers as soon as I saw they were available, and ran some comparisons between gfortran and ifort using Nek5000 (CFD software) in serial mode. I was surprised to find that gfortran was about 8-10 percent faster (repeatable over many runs). I played around with flags a lot and narrowed the difference down to -ffast-math. With that flag off the performance was very similar.

Take this with a grain of salt of course - it’s one program on one platform, but I just thought I’d share my experience…

For those of you familar with ifort, is there an equivalent of ffast-math in ifort?

2 Likes

You can always start with -fast, that applies some options that generally improve performance. It implies -xHost, which means optimize for the CPU you’re compiling on. Were you using an Intel CPU? It helps there more.

Hey @sblionel !

I was using an intel CPU, but a very old one… i7-4790. I used -xHost and -Ofast. For some reason -fast didn’t actually work - I got runtime errors in some library I didn’t recognize.

1 Like

For those seeking installation instructions on Linux, they can be found on the following sub-page:

5 Likes

I once read that Digital Visual Fortran (a Fortran 90 compiler for Windows) started as an unofficial skunkworks project by Digital developers. Then Digital was acquired by Compaq, Compaq merged with HP, and the HP compiler team and technology was acquired by Intel. I am grateful that through all shakeups, work continued on the compiler. It’s being made free is icing on the cake.

I am also grateful to the gfortran developers and to the g95 developer, who I will never forget. Having two free compilers that support much/all of Fortran 2003, 2008 and 2018 removes my excuse for not trying out features from those standards.

4 Likes

Not quite. Here is the sequence…

  1. DEC ported DEC Fortran 90 to Windows NT on Alpha processors - already had it for VMS and DEC/OSF1 (UNIX). It was command-line only and didn’t see much use.

  2. DEC approached Microsoft about licensing the Visual Studio IDE for the Alpha product. By that time, Microsoft was realizing that they would need to put in a lot of effort to bring their Fortran PowerStation product up to Fortran 95 (and resolve the many bugs). MS didn’t want to make this sort of investment and suggested instead that DEC take over for them in the X86 market. MS licensed Visual Studio '98 to DEC, along with the MSVC libraries, as well as other components such as the QuickWin library and Windows API declarations.

  3. DEC released Digital Visual Fortran 5 in 1997 and Microsoft withdrew Fortran PowerStation 4 from the market. This was DEC’s Fortran 90 compiler and (mostly) run-time library, with almost all of the PowerStation extensions added in. Alpha was supported too (on NT).

  4. In 1999, Compaq bought DEC. DVF became CVF (6.5 by then), the color scheme changed to red, and that was about it.

  5. August 2001, Intel acquires the Compaq Fortran team, some of the Compaq C++ team and most of the remaining Alpha engineering team. The Fortran team’s task was to throw out the (excellent) GEM compiler backend and replace it with Intel’s IL0. An Intel manager predicted it would take six months.

  6. September 2001, HP acquires Compaq. Note that this timeline means that at no time were we HP employees. The acquisition added some complications for the Intel deal, but they were eventually worked out. CVF continued with a minor update (6.6) and bug fixes

  7. 2004, Intel Visual Fortran 8 (previous Intel version was 7) was released, along with Intel Fortran for Linux. (Six months - right!) Itanium (remember that?) support was added. DEC had been working on a Linux version for a while, prior to the Intel deal, but never released it. Initially, it required that you have Visual Studio .NET already installed, but as of version 10, MS offered a “Premier Partner Edition” of VS that had the necessary bits, and Intel licensed that.

12 Likes

Thank you @sblionel for writing up the history. I would actually really like this to be written somewhere in a more permanent form, I wonder if we can have a section “History” at fortran-lang.org and have this there. Right now we have “Compilers” section:

We have done our best to collect all Fortran compilers. If there is any missing, please let us know.

Here is a history of the NAG compiler: https://www.nag.com/content/personal-history-nag-fortran-compiler

Right now the history is mostly remembered by people like @sblionel, @billlong, but newcomers like me do not necessarily know the backgrounds of the various efforts, and they are not well documented at places like Wikipedia. I think it’s important to preserve the history for future generations.

5 Likes

I’ll write up a longer history of DEC-heritage compilers soon. My knowledge pre-1978 is fuzzy, but I’ll do the best I can.

3 Likes

@sblionel thank you, that would be very valuable. 1978 forward would be awesome.

In my experience (some time ago), ifort gave significant performance gain for molecular dynamics codes, while not much (or essentially no gain) as compared to gfortran for electronic structure codes. I guess it may depend on how the type of calculation can benefit from so-called “vectorization”, though I am not sure about details…

After ifort-14 (which was free for the non-commercial edition), I mainly used gfortran for my programs (because I cannot use the license in my home or laptop), but I can try it now with ifort. I believe this is really nice :slight_smile:

4 Likes

As of early 2018 (last time I measured), Intel-built WRF (weather prediction) was about 3.5x faster than the GNU build, on Intel Xeon 8168.

4 Likes

In most of my tests, GFortran is about 150%-200% faster than ifort. But that greatly depends on the type of the test, the operations involved, and most importantly, the Intel-architecture-specific compiler optimizations. I guess that’s where Intel turns out to be faster.

But speed is not the only issue that matters. Sadly, GNU compilers are not built with -fPIC and therefore do not allow static linking of GFortran libraries with shared files. So one has to always carry around the library dependencies, which create a whole new set of issues, or let the users deal with it by themselves, which create all sorts of other headaches. On the flip side, Intel Fortran Compiler does not suffer from the same weakness, which makes it really superior to GFortran, in my opinion.

3 Likes