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

Cannot run 4.9+ on Apple Silicon

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker - P1
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.9.0-rc1, 5.0.0-rc0
    • Component/s: Build
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Backport Requested:
      v4.9
    • Sprint:
      Dev Platform 2021-05-17
    • Case:

      Description

      Mongo 4.9+ cannot start on M1 laptops:

      % /tmp/mms-automation/test/versions/mongodb-macos-x86_64-4.9.0-rc0/bin/mongod
      zsh: illegal hardware instruction  /tmp/mms-automation/test/versions/mongodb-macos-x86_64-4.9.0-rc0/bin/mongod
      

      Andrew Morrow tracked down that this is because the ISA targeting for the server build was upgraded in 4.9 to sandybridge, which uses AVX instructions that are not handled by Rosetta:
      https://developer.apple.com/documentation/apple-silicon/about-the-rosetta-translation-environment

      Rosetta translates all x86_64 instructions, but it doesn't support the execution of some newer instruction sets and processor features, such as AVX, AVX2, and AVX512 vector instructions.

      He recommended special case downgrading the macOS target ISA to something that doesn’t generate AVX until we have a native Apple Silicon build.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              acm Andrew Morrow
              Reporter:
              louisa.berger Louisa Berger
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: