Saleem Abdulrasool
5953d87d85
utils: add support to use the swift-driver as the driver
...
This is motivated by an experiment to build DocC with CMake which
exposed a bug in the Swift driver. This allows us to workaround that bug
with the Swift Swift driver.
2024-02-06 09:21:30 -08:00
Saleem Abdulrasool
4e971a4064
Merge pull request #71378 from compnerd/summary
...
utils: gussy up timing information summary for Windows
2024-02-05 08:13:08 -08:00
Saleem Abdulrasool
485ff3e7bc
utils: gussy up timing information summary for Windows
...
Emit this in a `finally` block ensuring that it is printed at the end
under all circumstances. Reduce the column width by making the checkout
`SourceCache` relative.
2024-02-04 11:20:23 -08:00
Saleem Abdulrasool
c6b0084c8f
utils: add support for testing self-hosted SPM
...
`-Test swiftpm` will use the self-hosted build of SPM to run the test
suite. By using the `SWIFTCI_USE_LOCAL_DEPS=1` environment variable, we
do reduce some of the cost of this by not recloning the repositories,
but the entire dependency tree must be built a second time due to the
switch in the build system.
2024-02-03 10:53:39 -08:00
Saleem Abdulrasool
17c1f4b034
Merge pull request #71355 from compnerd/summary
...
utils: introduce new `-Summary` option for `build.ps1`
2024-02-03 09:05:40 -08:00
Kavon Farvardin
558c91b8ec
Merge pull request #71359 from kavon/ncgenerics-preset
...
BuildScript: add ncgenerics preset
2024-02-02 18:10:40 -08:00
Kavon Farvardin
e47e51632a
BuildScript: add ncgenerics preset
...
This allows for simpler CI testing with NCGenerics enabled using this:
```
preset=ncgenerics,smoketest=macosx
@swift-ci Please test with preset macOS Platform
```
2024-02-02 15:15:20 -08:00
Alastair Houghton
4c7822cdac
Merge pull request #71213 from al45tair/eng/PR-121522431
...
[Frontend][AST][IRGen] Improve availability support.
2024-02-02 22:30:19 +00:00
Saleem Abdulrasool
b58792eb04
utils: enable a summary view on the toolchain build on Windows
...
This should help us understand where our build time is being spent.
Hopefully we can use this information to properly identify places to
reduce the cost of a build.
2024-02-02 14:17:08 -08:00
Saleem Abdulrasool
2da252e42a
utils: introduce new -Summary option for build.ps1
...
Add a new `-Summary` option to understand the build times expenditure.
This prints a summary at the end of the build time, though should be
further refined to include tests, auxiliary operations, and the like.
~~~
Arch Checkout BuildID Elapsed Time
---- -------- ------- ------------
x64 S:\SourceCache\swift-project\swift\tools\swift-inspect swift-inspect 00:00:00.2372939
x64 S:\SourceCache\swift-project\sqlite-3.43.2 sqlite-3.43.2 00:00:00.5062697
x64 S:\SourceCache\swift-project\zlib zlib-1.3 00:00:00.5615253
arm64 S:\SourceCache\swift-project\zlib zlib-1.3 00:00:00.5623726
x86 S:\SourceCache\swift-project\zlib zlib-1.3 00:00:00.6185541
x64 S:\SourceCache\swift-project\swift-system 2 00:00:00.6562858
x64 S:\SourceCache\swift-project\Yams 5 00:00:00.6647429
x64 S:\SourceCache\swift-project\swift-certificates 11 00:00:00.6649416
arm64 S:\SourceCache\swift-project\swift-corelibs-xctest 304 00:00:00.6688467
x64 S:\SourceCache\swift-project\swift-asn1 10 00:00:00.6795648
x64 S:\SourceCache\swift-project\swift-corelibs-xctest 104 00:00:00.6938559
x64 S:\SourceCache\swift-project\swift-argument-parser 6 00:00:00.7351350
x64 S:\SourceCache\swift-project\swift-tools-support-core 3 00:00:00.7400418
x64 S:\SourceCache\swift-project\indexstore-db 15 00:00:00.7402386
x86 S:\SourceCache\swift-project\swift-corelibs-xctest 204 00:00:00.7414125
x64 S:\SourceCache\swift-project\cmark cmark-gfm-0.29.0.gfm.13 00:00:00.7435080
x64 S:\SourceCache\swift-project\swift-crypto 8 00:00:00.7593080
arm64 S:\SourceCache\swift-project\libxml2 libxml2-2.11.5 00:00:00.7659147
x64 S:\SourceCache\swift-project\libxml2 libxml2-2.11.5 00:00:00.7885430
x64 S:\SourceCache\swift-project\sourcekit-lsp 16 00:00:00.8459008
arm64 S:\SourceCache\swift-project\icu\icu4c icu-69.1 00:00:00.8544044
x86 S:\SourceCache\swift-project\libxml2 libxml2-2.11.5 00:00:00.8552676
x64 S:\SourceCache\swift-project\icu\icu4c icu-69.1 00:00:00.8986529
x64 S:\SourceCache\swift-project\curl curl-8.4.0 00:00:00.9157392
arm64 S:\SourceCache\swift-project\curl curl-8.4.0 00:00:00.9292362
x64 S:\SourceCache\swift-project\swift-package-manager 12 00:00:00.9352117
x86 S:\SourceCache\swift-project\icu\icu4c icu-69.1 00:00:00.9890039
x86 S:\SourceCache\swift-project\curl curl-8.4.0 00:00:01.0041779
x64 S:\SourceCache\swift-project\llbuild 4 00:00:01.0835003
arm64 S:\SourceCache\swift-project\swift-corelibs-libdispatch 302 00:00:01.2923527
x64 S:\SourceCache\swift-project\swift-corelibs-libdispatch 102 00:00:01.2940821
x86 S:\SourceCache\swift-project\swift-corelibs-libdispatch 202 00:00:01.3725038
x64 S:\SourceCache\swift-project\swift-docc swift-docc 00:00:01.5638843
x64 S:\SourceCache\swift-project\swift-corelibs-foundation 103 00:00:03.2156545
arm64 S:\SourceCache\swift-project\swift-corelibs-foundation 303 00:00:03.2375292
x86 S:\SourceCache\swift-project\swift-corelibs-foundation 203 00:00:03.3768394
x64 S:\SourceCache\swift-project\swift 101 00:00:03.4123377
x86 S:\SourceCache\swift-project\swift 201 00:00:03.4822752
arm64 S:\SourceCache\swift-project\swift 301 00:00:03.5000946
x64 S:\SourceCache\swift-project\swift-collections 9 00:00:04.1620695
x64 S:\SourceCache\swift-project\swift-format 14 00:00:07.9155136
arm64 S:\SourceCache\swift-project\llvm-project\llvm 300 00:00:08.0239769
x64 S:\SourceCache\swift-project\llvm-project\llvm 100 00:00:08.0504294
x86 S:\SourceCache\swift-project\llvm-project\llvm 200 00:00:08.1190769
x64 S:\SourceCache\swift-project\swift-markdown 13 00:00:12.4397452
x64 S:\SourceCache\swift-project\swift-driver 7 00:00:24.9125831
x64 S:\SourceCache\swift-project\llvm-project\llvm 1 00:01:04.5879144
x64 S:\SourceCache\swift-project\llvm-project\llvm 0 00:01:10.9225001
~~~
2024-02-02 14:16:35 -08:00
Guillaume Lessard
114f235d17
Merge pull request #71167 from vanvoorden/vanvoorden/inclusive-language
...
[Inclusive Language][Comments][Documentation] migrate "sanity" checks to "soundness" checks
2024-02-02 10:27:34 -08:00
Alastair Houghton
e48b05f12c
[SwiftCompilerSources] Enable use of the -min-runtime-version option.
...
Turn on the use of `-min-runtime-version` when building the compiler.
rdar://121522431
2024-02-02 16:19:06 +00:00
Saleem Abdulrasool
a037974001
Merge pull request #71315 from compnerd/embedded
...
utils: adjust CMake flags for debug info handling
2024-02-02 08:04:32 -08:00
Michael Gottesman
c89f63ff27
Merge pull request #71233 from gottesmm/transfernonsendable-more-insts
...
[region-isolation] Add support for more instructions
2024-02-02 02:20:17 -08:00
Karoy Lorentey
ee10a4e06b
Merge pull request #71297 from lorentey/define-5.10
...
[stdlib] Define OS version numbers for SwiftStdlib 5.10
2024-02-01 14:38:12 -08:00
Saleem Abdulrasool
fe90ed91a6
utils: adjust CMake flags for debug info handling
...
Use the new CMake options for controlling debug information generation.
This matches the recommendations from sccache and avoids us trying to
map flags manually.
2024-02-01 11:28:38 -08:00
Saleem Abdulrasool
d021c54533
Merge pull request #71284 from compnerd/optionality
...
utils: clean up unnecessary cmake options for packaging
2024-02-01 08:17:57 -08:00
Karoy Lorentey
9f66bd0912
[stdlib] Define OS version numbers for SwiftStdlib 5.10
2024-01-31 16:06:49 -08:00
Saleem Abdulrasool
37c593b076
utils: fix debug info generation for the standard library
...
When we build the standard library, we use the just built compilers.
However, we would not pass the necessary flags to the linker to generate
the debug information (PDBs) which would then make debugging more
challenging than it already is.
2024-01-31 15:29:32 -08:00
Saleem Abdulrasool
086134164d
utils: clean up unnecessary cmake options for packaging
...
swift-format is no longer optional and is always built. The options
controlling the packaging have been removed. Update the invocation.
2024-01-31 13:16:13 -08:00
Saleem Abdulrasool
b58889ae55
utils: tweak cmark wiring
...
Use the installed image rather than the build tree for wiring up CMark.
This may be used across phases of the build, so it is better to use the
staged image.
2024-01-30 14:00:31 -08:00
Michael Gottesman
c28ad4eaec
[sil-mode.el] Add syntax highlighting for pack instructions.
2024-01-29 21:34:41 -08:00
Saleem Abdulrasool
81edeb1cab
utils: use named enumerator for target libraries
...
We would use integral values to identify the target library rather than
using a named enumerator. Change to a named enumerator and inline some
cases where we would explain the code by creating variables.
2024-01-29 13:44:29 -08:00
Saleem Abdulrasool
0dc8fbdb96
Merge pull request #70814 from compnerd/format
...
build: migrate to CMake based build of swift-format
2024-01-28 11:29:30 -08:00
Saleem Abdulrasool
1864caad5e
build: migrate to CMake based build of swift-format
...
This allows us to build swift-format with dynamic linking against the
toolchain build of the swift-syntax and swift-argument-parser packages.
Wire up the swift-markdown build and hoist the swift-format build prior
to sourcekit-lsp. This sets us up for supporting swift-format based
formatting in the LSP.
2024-01-26 15:51:29 -08:00
Mike Ash
4bc7726d43
Merge pull request #70900 from mikeash/swift-generic-metadata-builder-out-of-process
...
[Tools] Add a library to build specialized generic metadata out of process.
2024-01-26 10:50:34 -05:00
Rick van Voorden
f8ae46b3f3
[inclusive-language] changed sanity to soundness
2024-01-25 18:18:02 -08:00
Kavon Farvardin
b8cd7effeb
Merge pull request #70866 from kavon/ncgenerics-stdlib-building-v4
...
Build Stdlib with Noncopyable Generics (Part 4)
2024-01-25 07:09:38 -08:00
Doug Gregor
aa89306a70
Merge pull request #71130 from ahoppen/ahoppen/build-swift-format
...
[builds] Build swift-format as part of `mixin_linux_installation `
2024-01-24 20:20:39 -08:00
Mike Ash
4341102c92
[Tools] Add a library to build specialized generic metadata out of process.
...
This library uses GenericMetadataBuilder with a ReaderWriter that can read data and resolve pointers from MachO files, and emit a JSON representation of a dylib containing the built metadata.
We use LLVM's binary file readers to parse the MachO files and resolve fixups so we can follow pointers. This code is somewhat MachO specific, but could be generalized to other formats that LLVM supports.
rdar://116592577
2024-01-24 20:45:50 -05:00
Alex Hoppen
350b110849
[builds] Build swift-format as part of mixin_linux_installation
...
We need swift-format to be installed in the toolchain in order to run SourceKit-LSP tests that invoke the swift-format executable.
rdar://121548636
2024-01-24 17:41:23 -08:00
Saleem Abdulrasool
0d3f6a9f06
Merge pull request #70791 from compnerd/cmark
...
build: update for cmark build revamp and split the build
2024-01-24 14:40:23 -08:00
Tristan Labelle
efab1ffe01
Build.ps1: more detailed exception printing
2024-01-24 11:39:51 -05:00
Kavon Farvardin
b92fe5f2e9
[build-script] fix NoncopyableGenerics option
...
This patch introduces `--enable-experimental-noncopyable-generics` for
the build script. It replaces
`--swift-stdlib-experimental-noncopyable-generics`
The old build option only enables the feature when building the
stdlib, but if we've built the stdlib with NoncopyableGenerics, the
compiler should be hardwired to have that feature enabled, too.
This patch also introduces the `noncopyable_generics` lit parameter, so
that tests assuming the system was built with the feature can live
in-tree and be tested, if they specify `REQUIRES: noncopyable_generics`.
2024-01-23 22:41:59 -08:00
Alex Hoppen
623db31600
Merge pull request #71062 from ahoppen/ahoppen/install-swiftformat-in-linux-toolchains
...
Install swift-format into Linux toolchains
2024-01-23 07:30:46 -08:00
Alex Hoppen
376e21617c
Merge pull request #71042 from ahoppen/ahoppen/cross-compile-swiftformat
...
[build] Support cross-compilation of swift-format
2024-01-22 19:27:44 -08:00
Alex Hoppen
b28f124cda
Install swift-format into Linux toolchains
...
It looks like we were only installing swift-format into macOS toolchains. We should also build it on Linux toolchains so it can be installed there as well.
2024-01-22 09:29:33 -08:00
Alex Hoppen
acad2bf251
[build] Support cross-compilation of swift-format
...
This should build swift-format as a fat binary containing both an x86_64 and an arm64 slice in the open source toolchains.
rdar://121326143
2024-01-21 13:45:53 -08:00
Alex Hoppen
7b5fa6ec13
Merge pull request #71003 from ahoppen/ahoppen/install-swiftformat-for-lsp
...
[build] Install swift-format in all jobs that test sourcekit-lsp
2024-01-20 15:15:53 -08:00
Adrian Prantl
9b5da0d82f
Merge pull request #71010 from adrian-prantl/unskip
...
do not skip the early swift driver in LLDB presets
2024-01-20 08:55:12 -08:00
Saleem Abdulrasool
5bbead3ea3
Merge pull request #70962 from compnerd/squeaky-clean
...
build: add a `-Clean` option to build.ps1
2024-01-19 15:17:35 -08:00
Saleem Abdulrasool
9e4153499f
build: add a -Clean option to build.ps1
...
When the compiler changes, the SDK and tool builds do not notice the
compiler change due to the missing compiler tracking. This allows us to
quickly perform an incremental by not discarding the compiler build.
2024-01-19 10:34:46 -08:00
Artem Chikin
f7dcecd50b
Merge pull request #70996 from artemcm/DoNotSkipEarlyDriverLinuxPreset
...
Do not skip `earlyswiftdriver` in SwiftPM Linux CI Preset
2024-01-19 09:22:41 -08:00
Adrian Prantl
63972d15bd
do not skip the early swift driver in LLDB presets
2024-01-19 08:17:11 -08:00
Alex Hoppen
7ec0fcf8dc
[build] Install swift-format in all jobs that test sourcekit-lsp
...
With https://github.com/apple/sourcekit-lsp/pull/769 , sourcekit-lsp supports formatting that invokes swift-format from the toolchain and tests that test this behavior. For those to pass, we need to install swift-format into the toolchain on all jobs that test sourcekit-lsp.
2024-01-18 22:00:37 -08:00
Artem Chikin
58ee81284d
Do not skip earlyswiftdriver in SwiftPM Linux CI Preset
2024-01-18 15:14:45 -08:00
Allan Shortlidge
07a67437be
Merge pull request #64656 from artemcm/LegacyDeathBed
...
Deprecate Legacy driver by removing incremental builds and adding warnings
2024-01-18 08:55:59 -08:00
Yuta Saito
ab03e1ff31
Merge pull request #70981 from kateinoigakukun/yt/disable-lldb-tests-on-wasm-ci
2024-01-18 20:28:01 +09:00
Yuta Saito
709629393b
[build] Skip lldb tests on WebAssembly CI node
...
The test somehow fails on a specific CI node. I couldn't find the root
cause yet, so skip it for now to avoid more silent breakages.
2024-01-18 08:40:09 +00:00
Yuta Saito
a2256436cf
Merge pull request #70511 from kateinoigakukun/katei/fix-global-executor-selection-wasm
...
build: Explicitly set `SWIFT_ENABLE_DISPATCH` to build Wasm stdlib
2024-01-18 14:20:23 +09:00