Skip to content

Update compiler on Linux s390x #3630

Closed
Closed
@richardlau

Description

@richardlau

@miladfarca has found that there is a nasty gcc bug on s390x with std::optional has_value() (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106355) during review of https://chromium-review.googlesource.com/c/v8/v8/+/5246687 (where V8 is proposing to drop their custom v8::base::Optional for std::optional).

While the upstream gcc bug has supposedly been fixed in gcc 10.5.0, that isn't available via dnf on RHEL 8 as gcc-toolset-10 was "retired" in November 2022 (FWIW gcc-toolset-11 is also considered "retired"), which probably means it is unlikely to get updates (we'll check): https://access.redhat.com/support/policy/updates/rhel-app-streams-life-cycle

What we know so far:

Tested the bug (using the example in bugzilla) on ubi8:

  • gcc-toolset-10 with cc 10.3.1: broken
  • gcc-toolset-11 with cc 11.2.1: broken
  • gcc-toolset-12 with cc 12.2.1: ok

A quick scan of the Node.js codebase shows we are already using std::optional outside of V8, although I don't know if we're hitting the bug with those usages.

So we're probably going to have to move to at least gcc-toolset-12 for Linux on s390x, and the only question is when and whether we make the switch for existing release lines to be on the safe side. Switching to gcc-toolset-12 should be safe from a runtime compatibility perspective as the code will still be linked against the glibc and libstdc++ versions in base RHEL 8.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions