[cfe-dev] [llvm-dev] [RFC] Raise the minimum Visual Studio version to VS2019

Renato Golin via cfe-dev cfe-dev at lists.llvm.org
Wed Dec 1 04:50:14 PST 2021


On Wed, 1 Dec 2021 at 12:20, Aaron Ballman via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> That said, I'm also happy to see our GCC and Clang requirements
> updated if that's reasonable to do so. GCC 5.1 was released April 2015
> and Clang 3.5 was released Sept 2014, so these are not particularly
> new toolchains.


In the past, we have used availability in stable OSs as merit for upgrading
the minimum.

On *nix distros, release support usually ~2 years, give or take.

These are all old releases:
(Source: https://pkgs.org/)

Ubuntu 18.04 has clang 6 and gcc 7.3
Ubuntu 20.04 has clang 10 and gcc 9.3
Fedora 33 has clang 11 and gcc 9.2
Debian Stretch has clang 7 and gcc 6.1
Centos 8 has clang 12 gcc 8.5
FreeBSD 12 has clang 11 gcc 6.5 (and 9.3)
OpenSUSE 15 has clang 9 and gcc 7.5

Minimum clang and gcc is around  6.x.

I'm not sure on Mac, but I assume they have a more aggressive goals for the
system compiler than many of the Linux/BSD distros and probably have a
newer clang than most of them (at the same age).

With clang being the system compiler for Mac and BSD, getting a newer gcc
would be just a matter of looking at ports-equivalent.

On Windows, neither clang nor gcc are the system compiler, so not hard to
get the latest version.

Frankly, my biggest driver is the ability to
> eventually use C++17 in the code base. I believe the most responsible
> way for us to do that is to upgrade compilers before we switch default
> language modes so that we're not changing too much at once, which
> makes regressions easier to track down and report. However, getting a
> newer toolchain by itself is a good end result (we know we're doing
> the upgrades at some point and smaller version deltas are often less
> risky than larger version deltas).


+1 to all that.

Much of C++17 support is in GCC 6, but GCC 7 is a safer bet.
(Source: https://gcc.gnu.org/projects/cxx-status.html#cxx17)

Clang 5, 6 and 7 have varying degrees of C++17 support, with clang 8 being
the last that added something substantial.
(Source: https://clang.llvm.org/cxx_status.html#cxx17)

With that in mind, and the fact that *nix distros have ways to get a newer
compiler if needed (ports/PPA), I'd say:

Clang/GCC 6 is a safe minimum, but Clang/GCC 7 is a better move, if we
don't want to change it too soon.

cheers,
--renato
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20211201/b2e6ad82/attachment-0001.html>


More information about the cfe-dev mailing list