Commit Graph

867 Commits

Author SHA1 Message Date
Michael Gottesman
b16d4fa505 [semantic-arc] Add build-script option --enable-sil-ownership to turn on the SIL ownership model.
rdar://28685236
2016-10-11 11:29:12 -07:00
practicalswift
ce3b47e329 [gardening] PEP-8 fixes. 2016-09-25 20:41:55 +02:00
Michael Gottesman
6fd9dca2e6 [benchmark] Allow the number of test samples cmake will use to be specified from the command line.
The benchmark bot uses this functionality today to run the benchmarks. By
default build-script only uses 3 samples for each test. Given the noise on our
systems, this is definitely not sufficient for any sort of robust numbers.

Using this patch, I am going to change the benchmarking bot to take the minimum
of 20 samples as we do for our internal benchmarking. This should help make the
benchmark bot give better data. This will have as a cost cause the bot to take
more time. The testing time issue can be solved down the line by changing to a
protocol where we first do tests with a small number of samples (< 5). Then any
benchmark with a delta > 5% is rerun with 20 samples or perhaps until a
statistical criterion is satisfied. But until that is implemented, this at least
makes the bot useful.

There are other things that need to be changed on the benchmarking bot as well,
namely that it should build on a separate machine from which it is running the
benchmarks on. The benchmarking machine should be quiet and not have any work
being done on it. But that is also for another time.
2016-09-23 20:05:10 -07:00
Michael Gottesman
ab714cfa12 [vacation/gardening] fix python lint errors. 2016-08-12 10:11:18 -04:00
Michael Gottesman
4aad5801c8 [vacation/gardening] Move clang/swift version specification from build-script-impl => swift_build_support.products. 2016-08-12 10:07:20 -04:00
Michael Gottesman
72603eb944 [vacation/gardening] Move compiler-vendor code from build-script-impl => swift_build_support.products.
This is part of an effort to provide examples on how to migrate product
specific flags from build-script-impl => swift_build_support.products.
2016-08-12 10:07:20 -04:00
Michael Gottesman
88db3ab0e0 [vacation-gardening] Use more unittest.TestCase.assertIn instead of *.assertTrue(foo in bar). 2016-08-12 09:06:17 -04:00
Michael Gottesman
f82f38ef9b [vacation/gardening] Use canonical cmake names for TRUE/FALSE just out of paranoia. 2016-08-12 09:06:17 -04:00
Michael Gottesman
cab360d14a [vacation-gardening] Change method _compute_runtime_use_sanitizer => property _runtime_sanitizer_flags. NFC. 2016-08-12 09:06:17 -04:00
Michael Gottesman
14b2dd5296 [build-script] Move computation of LLVM_ENABLE_ASSERTIONS from build-script-impl to swift_build_support.products.LLVM. 2016-08-10 01:30:30 -04:00
Michael Gottesman
a56d6ac068 [build-script] Move llvm-targets-to-build to swift_build_support.products.LLVM from build-script-impl. 2016-08-10 01:30:30 -04:00
Robert Widmann
ed9fec7003 Fix python-lint build 2016-08-08 10:24:40 -07:00
practicalswift
3ebfbe4ef0 Remove unused imports. 2016-08-06 20:26:47 +02:00
Michael Gottesman
10bafd67e0 [build-script] Add support for passing into swift -DSWIFT_RUNTIME_USE_SANITIZERS flag. 2016-08-03 14:17:41 -07:00
Michael Gottesman
c28ce159cb [build-script] Add support for specifying per host cmake options.
These are computed by build-script and passed directly by build-script-impl into
cmake for the relevant target. We can now start to migrate per product cmake
options from build-script-impl into build-script.
2016-08-03 14:17:41 -07:00
Michael Gottesman
7611e12bf5 [build-script] Add support for compiling swift with tsan enabled. 2016-08-01 15:11:09 -07:00
Dmitri Gribenko
6eb40a084b build-script: support 4 version components in Clang versions 2016-07-13 22:08:24 -07:00
Russell Currey
c69b824d86 Use "powerpc64{le}" instead of "ppc64{le}"
A mix of "powerpc64" and "ppc64" existed, causing build failures.

Standardise on "powerpc64" and "powerpc64le", which are commonly used in
target triples, such as those generated by config.guess.

Signed-off-by: Russell Currey <ruscur@russell.cc>
2016-07-12 15:56:16 +10:00
Daniel Dunbar
b169cb55e6 Merge pull request #2988 from ddunbar/build-script-isolated-actions
[build-script] Add support for using isolated -impl actions.
2016-06-23 09:00:41 -07:00
Leo Giertz
0ce71c74f9 FreeBSD target is called x86_64 (but machine identifies as amd64) 2016-06-17 11:37:03 +02:00
Mishal Shah
3a945c4bbe [utils] Add test for optional_bool action 2016-06-16 13:33:09 -07:00
Mishal Shah
e4341ab990 [build-script] Add optional_bool action and update build-script to use it 2016-06-15 11:44:21 -07:00
Daniel Dunbar
b1d56ea216 [build-script] Add support for using isolated -impl actions.
- This change moves the top-level invocation driver loop into `build-script`
   and uses the `-impl` script to perform each individual action. Once landed
   and enabled, this will enable us to migrate the individual pieces of the
   `-impl` script into Python code in an incremental fashion.

 - This also introduces stub product definitions for each of the different projects
   we manage.

 - This works, but is disabled by default (`--no-legacy-impl`) because it
   severely impacts the performance of null builds (4x slower, currently) due to
   the `build-script-impl` parsing overhead. If only we had a JITing bash
   implementation...
2016-06-13 12:24:49 -07:00
SpringsUp
02ad66db3c [build-script] Infer --android platform flag by presence of a stdlib-target 2016-06-10 08:35:21 +02:00
practicalswift
285b6b526c [gardening] Fix typo. 2016-06-09 10:14:23 +02:00
practicalswift
856f0d6bde [gardening] First argument of a classmethod should be named 'cls' 2016-06-09 10:14:04 +02:00
Daniel Dunbar
3a4d99e6bf [swift_build_support] We don't run benchmarks on simulator platforms. 2016-06-08 20:49:29 -07:00
Daniel Dunbar
8a2fd1600b Merge pull request #2880 from ddunbar/build-script-compute-targets
[build-script] Compute targets in `build-script`
2016-06-08 20:26:18 -07:00
Daniel Dunbar
3e3fe3fd7c Merge pull request #2960 from ddunbar/freebsd-toolchain-crash
[swift_build_support] Fix crash in FreeBSD toolchain.
2016-06-08 19:24:52 -07:00
Daniel Dunbar
ee4a8432b1 [swift_build_support] Fix crash in FreeBSD toolchain.
- Reported in https://github.com/kylef/swiftenv/issues/36
2016-06-08 17:28:45 -07:00
Daniel Dunbar
d51507879a [build-script] Several PEP8 fixes. 2016-06-08 17:23:27 -07:00
Daniel Dunbar
f407cdfb30 [swift_build_support.targets] Add some additional metadata.
- This adds several platform/target properties used to configure the default
   behavior for a build.

 - This also adds an API to find a target from a name.
2016-06-08 17:23:00 -07:00
Daniel Dunbar
bf75c8f50a [build-script] Create explicit Platform and Target types.
- This is so that we can have a place to attach the additional metadata we need
   on platform or target specific behaviors.
2016-06-08 17:23:00 -07:00
Daniel Dunbar
3037b21e2d [swift_build_support] Change shell env to be a mapping.
- This is consistent with the `subprocess` API, which this module is otherwise
   closely related to, so I think this makes more sense than taking a list of
   key-value pairs.
2016-06-08 16:21:03 -07:00
Michael Gottesman
2e7d88e5b0 [build-script][lto] Migrate the num_*_parallel_lto_link_jobs code from build-script-impl into build support.
rdar://24717107
2016-06-07 20:59:13 -06:00
practicalswift
8df3859ce7 [gardening] Fix recently introduced typos. 2016-06-05 11:11:44 +02:00
Dmitri Gribenko
4577de4bed Merge pull request #2884 from rintaro/build-script-args-concat
[build-script] Introduce "concat" argument action
2016-06-04 18:02:08 -07:00
practicalswift
ab807c682f [gardening] PEP-8 fixes. 2016-06-04 22:39:30 +02:00
rintaro ishizaki
0d6e1b1154 [build-script] Introduce "concat" argument action
Get rid of unnecessary list of list argument.
2016-06-05 00:53:05 +09:00
practicalswift
ccdea7c7c7 [gardening] Fix "a" vs. "an" issues. 2016-06-04 09:21:08 +02:00
Dmitri Gribenko
07d0a62faf Merge pull request #2877 from apple/build-script-allow-non-zero-xcodebuild-sdk-version
build-script: allow non-zero exit codes from 'xcodebuild -version -sdk'
2016-06-03 18:02:59 -07:00
Dmitri Gribenko
c55e89f55a build-script: allow non-zero exit codes from 'xcodebuild -version -sdk'
Under certain obscure circumstances (incomplete SDKs), xcodebuild can
successfully work with the SDK and print its version number, but will
still exit with a non-zero code.  This change works around the issue by
ignoring the exit code.
2016-06-03 15:50:06 -07:00
practicalswift
57bccc8b06 [gardening] Fix inconsistent formatting. 2016-06-04 00:37:15 +02:00
rintaro ishizaki
3384d2d933 [build-script] Make --show-sdks fail if calling xcodebuild failed 2016-06-03 16:14:14 +09:00
rintaro ishizaki
308160a4d4 [build-script] Consistent use of shell.capture in swift_build_support
Eliminate direct `import subprocess`.
2016-06-03 12:09:54 +09:00
Daniel Dunbar
bb81448152 [utils] Rename print_command argument.
- Based on review feedback in PR#2836.
2016-06-02 08:53:48 -07:00
Daniel Dunbar
76a39000b4 Merge pull request #2836 from ddunbar/eliminate-SwiftBuildSupport-subprocess-functions
[build-script] Eliminate swift build support subprocess functions
2016-06-02 08:35:37 -07:00
rintaro ishizaki
5959dd2aa1 [build-script] Reject user-supplied '--common-cmake-options' argument
build-script doesn't support manually supplied `--common-cmake-options`.

Introduced argparse action 'arguments.action.unavailable'
2016-06-02 16:17:44 +09:00
Daniel Dunbar
e8b121b6a6 [util] Add swift_build_support.shell.capture.
- This is an analog to `call`, which returns the captured output of the
   command.
2016-06-01 22:57:42 -07:00
Daniel Dunbar
87a17001cc [utils] Switch some random scripts to shell.call. 2016-06-01 22:35:16 -07:00