Skip to content

@stdlib/os-arch returns architecture of node, not of the cpu. #837

@ArmelChesnais

Description

@ArmelChesnais

Description

pulling arch when running in an x64 build of Node on an arm64 CPU (mac m1) will return x64, not arm64.

This was discovered while trying to determine the CPU arch of an electron app running an x64 version of the app on an m1 mac (arm64).

Related Issues

No response

Questions

No.

Demo

No response

Reproduction

No response

Expected Results

arch value should be `arm64` when running in a NodeJS x64 build running on an arm64 CPU

Actual Results

arch value returns the NodeJS build arch, not the CPU arch.

Version

No response

Environments

Node.js

Browser Version

No response

Node.js / npm Version

16.15.0

Platform

No response

Checklist

  • Read and understood the Code of Conduct.
  • Searched for existing issues and pull requests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugSomething isn't working.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions