Skip to content

apple-m1 detected as the native CPU for rustc on apple-m2 #127448

Closed
@betelgeuse

Description

@betelgeuse

I tried this command

$ rustc --print target-cpus | head -n 2
Available CPUs for this target:
    native          - Select the CPU of the current host (currently apple-m1).

I expected to see this happen: explanation

I ran the command on a apple-m2 Macbook Pro so that should be selected as the native cpu.

Instead, this happened: explanation

apple-m1 was selected

Meta

rustc --version --verbose:

rustc 1.81.0-nightly (ed7e35f34 2024-07-06)
binary: rustc
commit-hash: ed7e35f3494045fa1194be29085fa73e2d6dab40
commit-date: 2024-07-06
host: aarch64-apple-darwin
release: 1.81.0-nightly
LLVM version: 18.1.7

Linking tracker #73908

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.O-appleOperating system: Apple (macOS, iOS, tvOS, visionOS, watchOS)T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.llvm-fixed-upstreamIssue expected to be fixed by the next major LLVM upgrade, or backported fixes

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions