Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-96838

Address -Warray-bounds warnings in immer on GCC 14.2.0

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • Fully Compatible
    • Programmability 2024-11-25

      The immer library which we vendor generates a few instances of -Warray-bounds on GCC 14.2.0. The offending code is in header files that our source files include, so although there are only two code locations that produce the warnings, a very large number of warnings are generated from a large number of locations in our first-party code.

      We should (in no particular order) either:
      1. Patch the vendored code to silence the warnings with #pragma.
      2. Consider removing our uses of the library.

      We should seriously consider option #2 because this library is only guaranteed to work against the C++14 standard on GCC 6 and Clang 3.8. We are currently trying to move to GCC 14.2.0 and Clang 19 on C++20 as part of SPM-3825. It's likely that this library will continue to pose more issues in future toolchain upgrades, and the project's use of very outdated compilers undermines confidence that the project will be able to detect and resolve bugs.

            Assignee:
            james.bronsted@mongodb.com James Bronsted
            Reporter:
            james.bronsted@mongodb.com James Bronsted
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: