No warning or error for use of PGI compilers

Issue #167 resolved
Paul Hargrove created an issue

When I tried PGI 18.4 on macOS today, I was surprised to find that there was no warning about the compiler being un-validated.

The compiler's --version output is

$ pgc++ --version

pgc++ 18.4-0 64-bit target on macOS -tp sandybridge
PGI Compilers and Tools
Copyright (c) 2018, NVIDIA CORPORATION.  All rights reserved.

And that appears to match the following "GOOD" pattern in utils/system-checks.sh

        elif echo "$CXXVERS" | egrep ' +\([^\)]+\) +([5-9]\.|[1-9][0-9])' 2>&1 > /dev/null ; then

We know PGI won't work at the moment (issue #166).
So, I propose:

--- a/utils/system-checks.sh
+++ b/utils/system-checks.sh
@@ -80,6 +80,8 @@ platform_sanity_checks() {
             COMPILER_BAD=1
         elif echo "$CXXVERS" | egrep 'Apple LLVM version ([8-9]\.|[1-9][0-9])' 2>&1 > /dev/null ; then
             COMPILER_GOOD=1
+        elif echo "$CXXVERS" | egrep 'PGI Compilers and Tools'  > /dev/null ; then
+            COMPILER_BAD=1
         elif echo "$CXXVERS" | egrep ' +\([^\)]+\) +[1-4]\.' 2>&1 > /dev/null ; then
             COMPILER_BAD=1
         elif echo "$CXXVERS" | egrep ' +\(ICC\) +(17\.0\.[2-9]|1[89]\.|2[0-9]\.)' 2>&1 > /dev/null ; then

However, the pattern that did match looks waaaay to permissive to me.

Comments (2)

  1. Dan Bonachea

    I agree with the proposal to mark PGI as known bad until we get around to fixing it.

    The overly permissive pattern is for catching GCC which unfortunately has a wildly wide --version output format (see the comments after the pattern), because it's easy for the packager to alter, such that /gcc/i does not even appear in the output! We could upgrade the logic to additionally match the "Free Software Foundation" copyright that always appears on the second line (thanks to gcc's militant GPL license), that would help but might still have some false positives.

  2. Log in to comment