|
| 1 | +- Feature Name: none |
| 2 | +- Start Date: 2025-07-23 |
| 3 | +- RFC PR: [rust-lang/rfcs#3841](https://github.com/rust-lang/rfcs/pull/3841) |
| 4 | +- Rust Issue: [rust-lang/rust#0000](https://github.com/rust-lang/rust/issues/0000) |
| 5 | + |
| 6 | +# Summary |
| 7 | +[summary]: #summary |
| 8 | + |
| 9 | +Demote target `x86_64-apple-darwin` from Tier 1 to Tier 2 with host tools as this platform's lifetime is limited. |
| 10 | + |
| 11 | +Tier 2 with host tools means that the `x86_64-apple-darwin` target, |
| 12 | +including tools like `rustc` and `cargo`, |
| 13 | +is guaranteed to build but is not guaranteed to pass tests. |
| 14 | + |
| 15 | +This RFC does **not** propose removing the target completely from the codebase. |
| 16 | + |
| 17 | +# Motivation |
| 18 | +[motivation]: #motivation |
| 19 | + |
| 20 | +The `x86_64-apple-darwin` target has no long-term future. |
| 21 | +Upcoming changes will affect Rust's ability to ensure that the target meets the Tier 1 requirements, |
| 22 | +so we should demote it to Tier 2 with host tools in a controlled fashion. |
| 23 | + |
| 24 | +## A brief timeline |
| 25 | + |
| 26 | +- 2020-06-22: Apple [announced plans][trans] to shift away from the x86\_64 architecture. |
| 27 | +- 2020-12-31: Rust [promoted `aarch64-apple-darwin`][aarch-tier-2] to Tier 2 with host tools. |
| 28 | +- 2023-06-05: Apple [announced the replacement][trans] of the last x86\_64 hardware. |
| 29 | +- 2023-10-02: GitHub [announces public GitHub Actions runners][m1-runners] for Apple silicon. |
| 30 | +- 2024-10-17: Rust [promoted `aarch64-apple-darwin`][aarch-tier-1] to Tier 1. |
| 31 | +- **2025-07-23**: This RFC opened. |
| 32 | +- 2025-09-01: GitHub [will discontinue][macos-13-sunset] providing free macOS x86\_64 runners for public repositories. |
| 33 | +- 2025 (Fall): [macOS 26][tahoe] will be the last macOS to support the x86\_64 architecture. |
| 34 | +- 2027: The [Rosetta 2][trans] compatibility layer will be mostly removed. |
| 35 | + |
| 36 | +[trans]: https://en.wikipedia.org/wiki/Mac_transition_to_Apple_silicon |
| 37 | +[aarch-tier-2]: https://blog.rust-lang.org/2020/12/31/Rust-1.49.0/#64-bit-arm-macos-and-windows-reach-tier-2 |
| 38 | +[aarch-tier-1]: https://blog.rust-lang.org/2024/10/17/Rust-1.82.0/#macos-on-64-bit-arm-is-now-tier-1 |
| 39 | +[m1-runners]: https://github.blog/changelog/2023-10-02-github-actions-apple-silicon-m1-macos-runners-are-now-available-in-public-beta/ |
| 40 | +[macos-13-sunset]: https://github.blog/changelog/2025-07-11-upcoming-changes-to-macos-hosted-runners-macos-latest-migration-and-xcode-support-policy-updates/#macos-13-is-closing-down |
| 41 | +[tahoe]: https://en.wikipedia.org/wiki/MacOS_Tahoe |
| 42 | + |
| 43 | +## `x86_64-apple-darwin` popularity |
| 44 | + |
| 45 | +Looking at the [public download statistics][dl-stats] for the previous month (retrieved on 2025-07-21), |
| 46 | +we can see that `x86_64-apple-darwin` has substantially fewer downloads than `aarch64-apple-darwin`: |
| 47 | + |
| 48 | +[dl-stats]: https://p.datadoghq.com/sb/3a172e20-e9e1-11ed-80e3-da7ad0900002-60425c7cb1b7beb2e8959a305a301c0c?fromUser=false&refresh_mode=sliding&from_ts=1750525313022&to_ts=1753117313022&live=true |
| 49 | + |
| 50 | +### `rustc` |
| 51 | + |
| 52 | +| platform | downloads | percentage | |
| 53 | +|----------------------------|----------:|-----------:| |
| 54 | +| `x86_64-unknown-linux-gnu` | 194.38M | 81.58% | |
| 55 | +| `aarch64-apple-darwin` | 7.15M | 3.00% | |
| 56 | +| `x86_64-apple-darwin` | 2.74M | 1.15% | |
| 57 | + |
| 58 | +### `std` |
| 59 | + |
| 60 | +| platform | downloads | percentage | |
| 61 | +|----------------------------|----------:|-----------:| |
| 62 | +| `x86_64-unknown-linux-gnu` | 95.12M | 66.20% | |
| 63 | +| `aarch64-apple-darwin` | 4.82M | 3.35% | |
| 64 | +| `x86_64-apple-darwin` | 2.76M | 1.92% | |
| 65 | + |
| 66 | +# Guide-level explanation |
| 67 | +[guide-level-explanation]: #guide-level-explanation |
| 68 | + |
| 69 | +The first release after this RFC is merged will be the last one with Tier 1 support for the `x86_64-apple-darwin` target. |
| 70 | +The release after that will demote the target to Tier 2 with host tools, |
| 71 | +which means it will not be tested by CI. |
| 72 | + |
| 73 | +Once this RFC is merged, |
| 74 | +a blog post will be published on the main Rust Blog announcing the change to alert users of the demotion. |
| 75 | + |
| 76 | +The demotion will also be mentioned in the release announcement for the last |
| 77 | +release with Tier 1 support, as well as the first release with Tier |
| 78 | +2 support. |
| 79 | + |
| 80 | +# Reference-level explanation |
| 81 | +[reference-level-explanation]: #reference-level-explanation |
| 82 | + |
| 83 | +The CI setup for [`rust-lang/rust`][r-l/r] will be modified to change the `dist-x86_64-apple` builder to no longer build the tests or run them. |
| 84 | + |
| 85 | +[r-l/r]: https://github.com/rust-lang/rust |
| 86 | + |
| 87 | +# Drawbacks |
| 88 | +[drawbacks]: #drawbacks |
| 89 | + |
| 90 | +Without automated testing, |
| 91 | +this target will likely deteriorate more quickly. |
| 92 | + |
| 93 | +Users may be relying on Rust's Tier 1 support to provide confidence for their own artifacts. |
| 94 | +These users will be stuck on an old compiler version. |
| 95 | + |
| 96 | +# Rationale and alternatives |
| 97 | +[rationale-and-alternatives]: #rationale-and-alternatives |
| 98 | + |
| 99 | +- Rust CI could use emulation, |
| 100 | + such as that provided by [Rosetta 2][rosetta-2]. |
| 101 | + Lightweight experiments show that this may increase CI times by a factor of 3 |
| 102 | + (e.g. a step taking 200 seconds would now take 600 seconds). |
| 103 | + This would be a temporary solution, |
| 104 | + as eventually Apple will [sunset Rosetta 2][trans]. |
| 105 | + |
| 106 | +- The Rust Foundation could pay for GitHub Actions runners that will continue to use the x86\_64 architecture, |
| 107 | + such as `macos-13-large`, `macos-14-large`, or `macos-15-large`. |
| 108 | + This would be a temporary solution, |
| 109 | + as eventually GitHub will [sunset all x86\_64-compatible runners][n-1-policy]. |
| 110 | + |
| 111 | +- A third party could indefinitely provide all appropriate CI resources for the x86\_64 architecture. |
| 112 | + No such third party has made themselves known, |
| 113 | + nor has the Rust infrastructure team determined how to best integrate such resources. |
| 114 | + |
| 115 | +[rosetta-2]: https://en.wikipedia.org/wiki/Rosetta_(software) |
| 116 | +[n-1-policy]: https://github.com/actions/runner-images?tab=readme-ov-file#software-and-image-support |
| 117 | + |
| 118 | +# Prior art |
| 119 | +[prior-art]: #prior-art |
| 120 | + |
| 121 | +- The `i686-pc-windows-gnu` target was demoted in [RFC 3771][rfc-3771]. |
| 122 | + Similar to this RFC, |
| 123 | + the ability to reliably test the target was questionable. |
| 124 | + |
| 125 | +- The `i686-apple-darwin` target was demoted in [RFC 2837][rfc-2837]. |
| 126 | + Similar to this RFC, |
| 127 | + relevant hardware was no longer produced and it had been announced that upcoming operating systems would no longer support the architecture. |
| 128 | + |
| 129 | +[rfc-2837]: https://rust-lang.github.io/rfcs/2837-demote-apple-32bit.html |
| 130 | +[rfc-3771]: https://rust-lang.github.io/rfcs/3771-demote-i686-pc-windows-gnu.html |
| 131 | + |
| 132 | +# Unresolved questions |
| 133 | +[unresolved-questions]: #unresolved-questions |
| 134 | + |
| 135 | +- None |
| 136 | + |
| 137 | +# Future possibilities |
| 138 | +[future-possibilities]: #future-possibilities |
| 139 | + |
| 140 | +`aarch64-apple-darwin` could be demoted to Tier 3 or support completely removed. |
| 141 | +There's no strong technical or financial reason to do this at this point in time. |
| 142 | +Should further demotions be proposed, |
| 143 | +those will be evaluated separately and on thier own merits, |
| 144 | +using the [target tier policy][tier-policy] as guidance. |
| 145 | + |
| 146 | +[tier-policy]: https://doc.rust-lang.org/stable/rustc/target-tier-policy.html |
0 commit comments