PGI link failure for lib at C++11 and tests at C++17

Issue #289 resolved
Paul Hargrove created an issue

We have recently begun using the CI to perform "mixed" tests in which we specify a -std=c++NN when building tests, having NOT specified any at UPC++ installation time. This is motivated by the case previously observed (and resolved) in issue #181.

On one ppc64el/PGI tester configured to build tests with -std=c++17 (and libupcxx receiving the default of -std=c++11) we see the majority of the tests fail to link with:

/usr/include/c++/7/new:197: undefined reference to `__builtin_launder'

Full output for one test is here.

For the moment, this issue is assigned to me pending at least the following:

  1. Verify that this is not an installation error such that PGI is expecting C+17 "bits" from g++'s libstc++ that are not present due to too-old version
  2. Provide complete verbose compiler and linker output to isolate what differs between a C++11 and C++17 compilation of our tests/

Comments (7)

  1. Paul Hargrove reporter

    Re: "verify that this is not an installation error"

    I am still investigating.
    The original install was using g++-7 and its libstdc++.
    Updating that to a distro-provided g++-8 did not change the failures.
    I am building GCC 9.2 now...

    I have confirmed that the link lines for -std-c++{11,14,17} are identical other than the temporary .o file name.

  2. Paul Hargrove reporter

    Manual testing with a PGI install against a GCC-9.2.0 build appears to be working correctly.
    I will plan to mark this issue resolved once the problematic configuration has been rerun.

    This seems to highlight a deficiency in pgc++: its inability to inform the user that the libstdc++ from GCC is not sufficient for the requested -std=c++NN.

    While I have looked (more than once) for some table of required version in PGI's installation documentation, I have yet to find this information.

  3. Paul Hargrove reporter

    I will plan to mark this issue resolved once the problematic configuration has been rerun.

    Unfortunately, using the new install of PGI with GCC-9.2.0 I am seeing a compile-time error and not reaching the previously-failing link step.

    So the status of this issue remains indeterminate.

  4. Paul Hargrove reporter

    This issue is "on hold" pending sorting out issue #290 in which we cannot build libupcxx with pgc++ -std=c++17.

  5. Dan Bonachea

    workaround issue #289: link failure for PGI with -std=c++17

    PGI does not correctly implement std::launder as of the latest v19.10, and it always generates a link failure (issue #297).

    Workaround this by avoiding the call when compiling w/PGI.

    Resolves issue #289

    → <<cset 1ed4faf0808b>>

  6. Log in to comment