Commit Graph

9681 Commits

Author SHA1 Message Date
elsa 1e3e681584 Remove deprecated PrintCSEInternals flag (#89248)
Resolves rdar://177222636

The -print-cse-internals flag was deprecated as a part of the Swift
rewrite of the CSE pass.
It was still being used in
[utils/check-incremental](https://github.com/swiftlang/swift/blob/2ed7079b9bdf4f2583577c4fb37b5881af65236b/utils/check-incremental#L109-L110).
2026-05-19 12:25:57 -07:00
Slava Pestov 6ee56fea53 resolve-crashes.py: Special-case %target-swift-ide-test
Resolving an IDE crasher should remove the "not" entirely, because
swift-ide-test exits with code 0 even when the source is invalid.
2026-05-18 10:50:11 -04:00
Michael Gottesman 233c2bc947 Merge pull request #88736 from gottesmm/pr-61f7f1f980647b7d2d8c9c2e7e033eb05763bce2
[swift-snapshot-tool] Improve swift-snapshot-tool bisect reliability and cache GitHub API calls
2026-05-16 16:12:04 -07:00
Aviva 8c176b0075 Merge pull request #89107 from swiftlang/fix-typo
Encode the minimum OS version in ToolchainInfo.plist (fix typo)
2026-05-14 12:38:11 -07:00
Mishal Shah 55fbca88bc Merge pull request #89052 from swiftlang/shahmishal/update-checkout-stable-20260427
Update rebranch aliases to stable/20260427
2026-05-13 14:54:41 -07:00
Jake Petroules 306b4396f4 Encode the minimum OS version in ToolchainInfo.plist (fix typo)
Fix typo from initial change in #89062
2026-05-13 10:19:55 -07:00
finagolfin f0d8239cae Merge pull request #88435 from finagolfin/droid-23
build.ps1: change the minimum Android API to 23
2026-05-13 22:44:51 +05:30
eeckstein 5fdba8c57b Merge pull request #89056 from eeckstein/fix-scale-tests
tests: don't fail if instruction counts are not available for scale tests
2026-05-13 06:37:18 +02:00
Jake Petroules f86d26d39d Encode the minimum OS version in ToolchainInfo.plist (#89062)
The packaging scripts will use this to populate <allowed-os-versions> in
the final toolchain .pkg distribution
2026-05-12 20:13:39 -07:00
Saleem Abdulrasool 7fdb7c3804 Merge pull request #89054 from compnerd/no-networking
utils: avoid re-cloning the sources for EarlySwiftDriver
2026-05-12 16:25:22 -07:00
Erik Eckstein eaff604f41 tests: don't fail if instruction counts are not available for scale tests
Instead of explicitly limiting those tests to specific platforms, just ignore "No data" results.

rdar://176820820
2026-05-12 21:03:36 +02:00
Saleem Abdulrasool f230c7552c utils: avoid re-cloning the sources for EarlySwiftDriver
We already have a checkout for the dependencies of early-swift-driver.
Reuse the existing sources rather than checking them out from git again.
2026-05-12 11:20:25 -07:00
Mishal Shah 0443749d84 Update rebranch aliases to stable/20260427 2026-05-12 11:14:01 -07:00
Charles Zablit 01f99bfe81 Merge pull request #88712 from charles-zablit/cz/update-checkout/terminal-width
[update-checkout] fix duplicate lines on Windows
2026-05-12 18:23:24 +01:00
Karoy Lorentey 285fd54fde Merge pull request #88900 from lorentey/bump-swift-version
Bump Swift version to 6.5
2026-05-11 18:28:56 -07:00
Hamish Knight 4a9aedea07 [build-script] Set caching ninja wrapper on toolchain after writing
Make sure we only set it on the toolchain after having written out
the script. This ensures we don't attempt to build ninja from source.
2026-05-08 15:28:34 +01:00
Justice Adams dee72d71e2 [ci] limit parallel link jobs in buildbot_linux_base to 4 (#88888)
* limit `LLVM_PARALLEL_LINK_JOBS` to 4 on CI to prevent OOM

Seems to fail during the link phase of
```
FAILED: [code=1] unittests/Disassembler/DisassemblerTests 
```

Seen on both ubuntu 2604 and Debian 13
2026-05-07 08:23:52 -07:00
Charles Zablit 7450dd7793 [update-checkout] fix duplicate lines on Windows 2026-05-07 15:13:00 +01:00
Erik Eckstein 15711e20b1 utils: add option to do a simple 3-point test with utils/scale-test and check the superlinear factor
This is useful for general compile time regression tests which check overall user time of the whole compilation pipeline.
2026-05-07 09:52:09 +02:00
Karoy Lorentey da885c09e8 Bump Swift Compiler/Stdlib/Runtime version to 6.5 2026-05-06 16:21:38 -07:00
Karoy Lorentey acc6772444 [stdlib] Define an availability macro for SwiftStdlib 6.5 2026-05-06 16:21:27 -07:00
Steven Wu a87c1203fb Merge pull request #88608 from cachemeifyoucan/eng/PR-caching-swift-build
[build-script] Add --enable-caching support with clang-cache and Swift compilation caching
2026-05-05 11:36:52 -07:00
Saleem Abdulrasool 60652afe18 Merge pull request #88761 from compnerd/legacy
utils: rename `Build-SDK` to `Build-LegacySDK`
2026-05-04 21:16:16 -07:00
Mishal Shah 31cc2f7256 Add support for release/6.4.x branch 2026-05-04 16:12:04 -07:00
Doug Gregor f6fd1d8025 Merge pull request #88674 from DougGregor/embedded-swift-armv8m
[Embedded] Build standard library & friends for ARMv8-M and ARMv8.1-M
2026-05-03 23:45:17 -07:00
Finagolfin 9f538d5534 build.ps1: change the minimum Android API to 23 2026-05-03 09:56:03 +05:30
Saleem Abdulrasool 995cfa288a utils: rename Build-SDK to Build-LegacySDK
This is preparatory work to allow us to build multiple
"experimental"-style SDKs for bootstrapping.
2026-04-30 08:30:07 -07:00
Saleem Abdulrasool bc94724324 Merge pull request #88711 from compnerd/examples
utils: avoid building examples in ArgumentParser
2026-04-30 08:11:47 -07:00
Saleem Abdulrasool 884952de72 Merge pull request #88705 from compnerd/extraction
utils: extract Build-Bootstrap{Foundation,Testing}Macros (NFC)
2026-04-30 08:08:36 -07:00
Leonard Grey 7267ed5d93 build.ps1: Add missing wildcards in ConvertTo-ThickLayout filters
Should fix build
2026-04-29 19:29:43 -04:00
Steven Wu 72c8c21104 [build-script] Add --enable-caching support with clang-cache and Swift compilation caching
Add a new --enable-caching option that enables compilation caching for both
C/C++ (via clang-cache as compiler launcher) and Swift code (via
-cache-compile-job flags when bootstrapping=hosttools).

New options:
- --enable-caching: main toggle, incompatible with --sccache/--distcc
- --caching-cas-path: CAS directory (default: $BUILD_ROOT/cas)
- --caching-depscan-socket: depscan daemon socket path
- --caching-plugin-path: CAS plugin library path
- --caching-plugin-option: CAS plugin options (repeatable)
- --caching-prefix-map: enable source/SDK/toolchain prefix mapping
- --caching-remote-service-path: remote caching service with auto
  plugin inference from Xcode and implied prefix mapping

The build script starts a clang-cache depscan daemon with reliable cleanup
via atexit and SIGTERM handlers. Per-product build directories get .cas-config
and compilation-prefix-map.json files written automatically.

Caching flags are applied to all Swift host compilation targets: compiler
sources, pure-swift host libraries (ASTGen, macros), swift-syntax, and
the new runtime build when --build-runtime-with-host-compiler is used.

When not using --caching-remote-service-path, enables CAS backend
(-Xfrontend -cas-backend -Xllvm -cas-friendly-debug-info) unless
SWIFT_CACHE_DISABLE_MCCAS is set.

A ninja wrapper is generated at build/<subdir>/build-utils/ninja for
cached incremental builds outside the build-script.

rdar://155876033

Assisted-By: Claude
2026-04-29 14:42:17 -07:00
Michael Gottesman 6ac95fd21c [swift-snapshot-tool] When bisecting also emit the first failing snapshot.
The reason why I am changing this is that when one runs bisect with --invert,
the last successful snapshot is actually the snapshot where the test case last
failed. We want the tool to also tell us the first place it succeeded rather
than us having to use git to find it ourselves.
2026-04-29 12:12:27 -07:00
Michael Gottesman dbd38830e0 [swift-snapshot-tool] Add a cache so we aren't hitting github too hard. 2026-04-29 12:12:27 -07:00
Michael Gottesman 075113357f [swift-snapshot-tool] When bisecting use <= rather than <. 2026-04-29 12:12:27 -07:00
Hiroshi Yamauchi eebbc12422 [Windows] Enable incremental dependency scan for CAS (#88715)
- **Explanation**: This enables incremental dependency scan for CAS on
the Windows toolchain build, which bring small but meaningful speedup in
incremental builds with CAS enabled.
- **Scope**: It's a simple flag flip. The flag is already used in the
swift driver tests and is known to work.
- **Issues**: None.
- **Risk**: Low. CAS isn't enabled by default.
- **Testing**: Local toolchain build for Windows and the swift CI.
2026-04-29 10:16:52 -07:00
Saleem Abdulrasool a7b9f4e188 utils: avoid building examples in ArgumentParser
The examples are not distributed, avoid building them.
2026-04-28 09:51:25 -07:00
Saleem Abdulrasool 556da1e69f utils: extract Build-Bootstrap{Foundation,Testing}Macros (NFC)
The two bootstrap macro builds were inlined directly in the main build
sequence as raw Build-CMakeProject calls, inconsistent with every other
build step which is expressed as Invoke-BuildStep <Function> <Platform>.
Extract them into named functions so the build sequence is a uniform list
of Invoke-BuildStep invocations.
2026-04-28 06:34:47 -07:00
Saleem Abdulrasool c5f8db89d5 Merge pull request #88412 from Steelskin/fabrice/debug-format-unification
utils: Unify Debug Format handling in build.ps1
2026-04-27 17:53:45 -07:00
Saleem Abdulrasool b8ab21c5ce Merge pull request #88615 from compnerd/cleanups
utils: preparatory cleanup for bootstrapping support
2026-04-27 17:51:47 -07:00
Evan Wilde ae50c88648 Merge pull request #87293 from etcwilde/ewilde/runtimes-android-sysroot
Android: Use CMAKE_SYSROOT for Android sysroot
2026-04-25 11:26:53 -07:00
Doug Gregor f161a60e12 [Embedded] Build standard library & friends for ARMv8-M and ARMv8.1-M
Implements rdar://152598746.
2026-04-25 08:33:14 -07:00
Saleem Abdulrasool f974480e3f utils: inline single use Get-PythonLibName helper (NFC) 2026-04-22 15:29:30 -07:00
Saleem Abdulrasool 13eaec70b9 utils: introduce Get-SelectedSDKBuilds helper (NFC)
Centralise the enumeration of selected SDKs to make the code clearer to
read.
2026-04-22 15:29:30 -07:00
Saleem Abdulrasool 44f918d686 utils: introduce a ConvertTo-ThickLayout helper
Reduce the duplication for the thin to thick conversion that we do on
the SDKs. While it is harder now to identify when the conversion can be
removed, this makes it easier to maintain.
2026-04-22 15:29:30 -07:00
Saleem Abdulrasool da6be7fa65 utils: deduplicatee the SDK dependency building (NFC)
This creates a helper to build all the SDK dependencies for a given
platform. It is a purely structural change without impacting what is
built.
2026-04-22 15:29:30 -07:00
Saleem Abdulrasool 434ddcf3c2 utils: remove dead code from build.ps1 (NFC)
Remove some unused codepaths and unnecessary parameters in the
implementation. This is a pure clean up pass that does not impact the
execution.
2026-04-22 15:29:30 -07:00
Alastair Houghton dc41abd8ee Merge pull request #88601 from hjyamauchi/issue88578
Fix the cross-compiled Windows ARM64 NoAsserts toolchain
2026-04-22 18:11:37 +01:00
Kavon Farvardin ad0ea4a1b7 Merge pull request #88495 from kavon/relative-indexing-reparentable
Reparenting: use resilient indexing to access base witness table
2026-04-22 02:57:04 -07:00
Hiroshi Yamauchi 741b1d158d Fix the cross-compiled Windows ARM64 NoAsserts toolchain
Issue https://github.com/swiftlang/swift/issues/88578
2026-04-21 17:50:09 -07:00
Hamish Knight 23218f3062 [test] Add some more known crashers (#88559)
- Explanation: Adds new tests to the repo and makes a couple of minor
swift-dev-utils/crash-reduce improvements (scripts only used at-desk)
- Scope: test/utils
- Issue: N/A
- Risk: None
- Testing: N/A
- Reviewer: TBD
2026-04-21 01:47:29 +01:00