Skip to content

Optionally download platforms after installing an Xcode - #868

Closed
anciltech wants to merge 4 commits into
XcodesOrg:mainfrom
anciltech:feature/auto-download-platforms
Closed

anciltech wants to merge 4 commits into
XcodesOrg:mainfrom
anciltech:feature/auto-download-platforms

Conversation

@anciltech

@anciltech anciltech commented Sep 29, 2026 •

Copy link
Copy Markdown

Superseded by Platform management: detection, automatic downloads and safe removal.

Summary

Most developers need the same simulator platforms for every Xcode (e.g. iOS and watchOS), and have to install them by hand after each Xcode install.

Adds Settings › Downloads › Platforms:

  • Download all platforms, or
  • a checkbox per platform: iOS, watchOS, tvOS, visionOS.

When Xcodes starts installing an Xcode, it also starts downloading the selected simulator runtimes that match that Xcode's SDK builds and this Mac's architecture variant (the same variant the info pane's Platforms picker uses). One runtime per platform, all in parallel with each other and with the Xcode download (like pressing several Install buttons in the info pane), skipping platforms that are already installed or installing. Nothing changes when no platform is selected (the default).

iPhone Duo needs no separate option: its simulator is a device type in the iOS 27.1 runtime, so selecting iOS covers it.

Runtimes are installed through the existing downloadRuntime(runtime:) path, the same as the Install buttons in the info pane; for cryptex runtimes that is xcodebuild -downloadPlatform, which uses the selected Xcode.

New strings: AutoDownloadPlatforms, AutoDownloadPlatforms.All, AutoDownloadPlatformsDescription (English only for now).

Why parallel: measured

Downloading platforms one at a time vs. in parallel, with the same command Xcodes uses (xcodebuild -downloadPlatform <platform> -buildVersion <version> -architectureVariant arm64, plus -exportPath so nothing was installed). Each round used a different tvOS + watchOS version pair so no run could reuse another's download. Apple silicon Mac, Xcode 27.0, home connection, 29 Sep 2026.

tvOS + watchOS Mode Size Time Throughput
26.4 one at a time 7.48 GB 214 s 35 MB/s
26.1 one at a time 7.28 GB 266 s 27 MB/s
26.2 parallel 7.31 GB 129 s 57 MB/s
26.0 parallel 7.19 GB 100 s 72 MB/s
  • A single runtime download ran at 24–43 MB/s (average ~34 MB/s over five downloads), well below what the connection can do; two at once reached 57–72 MB/s combined.
  • For ~7.4 GB of platforms: ~240 s one at a time vs. ~115 s in parallel, about half the time (~2× faster). With iOS (~8 GB) and visionOS (~7.5 GB) selected too, the saving grows accordingly, and it all overlaps with the Xcode download itself.
  • Concurrent xcodebuild -downloadPlatform runs worked without errors.

Excluded: a 26.3 round (no Apple silicon-only 26.3 runtimes exist) and a 26.5 round where tvOS resumed an earlier partial download.

Tests

  • test_AutoDownloadPlatformsSelection_RoundTrips
  • test_RuntimesToAutoDownload_PicksSelectedPlatformsMatchingSDKsAndArchitecture (platform filter, SDK match, architecture variant, skips installed)
  • test_RuntimesToAutoDownload_NothingSelectedDownloadsNothing

anciltech and others added 4 commits September 29, 2026 16:31
Add Settings > Downloads > Platforms: "Download all platforms" or a
checkbox per platform (iOS, watchOS, tvOS, visionOS). After Xcodes
installs an Xcode, it downloads the selected simulator runtimes that
match that Xcode's SDKs and this Mac's architecture variant, one at a
time, skipping platforms that are already installed or installing.

Runtimes are installed the same way as the Install buttons in the info
pane (xcodebuild -downloadPlatform for cryptex runtimes, which uses the
selected Xcode).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Start the automatic platform downloads when an Xcode install starts
instead of after it finishes. Runtimes don't depend on the new Xcode
being installed, so this saves waiting for the Xcode download and
unarchive first. Platforms still download one at a time.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Start every selected platform at once, like pressing several Install
buttons in the info pane, instead of one after another. Mention in the
setting's description that iOS includes the iPhone Duo simulator, which
is a device type in the iOS 27.1 runtime rather than its own platform.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant