Commit Graph

17 Commits

Author SHA1 Message Date
Ben Barham
c163e0fe5e [Tests] Make OS features consistent
lit.py currently allows any substring of `target_triple` to be used as a
feature in REQUIRES/UNSUPPORTED/XFAIL. This results in various forms of
the OS spread across the tests and is also somewhat confusing since they
aren't actually listed in the available features.

Modify all OS-related features to use the `OS=` version that Swift adds
instead. We can later remove `config.target_triple` so that these don't
the non-OS versions don't work in the first place.
2022-05-20 19:51:23 -07:00
Josh Soref
760343f478 Spelling test moduleinterface (#58579)
* spelling: because

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: flaky

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

* spelling: the

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

Co-authored-by: Josh Soref <jsoref@users.noreply.github.com>
2022-05-05 16:58:25 -07:00
Ben Langmuir
202c9a7b24 Disable test/ModuleInterface/swift_build_sdk_interfaces/ignore-non-stdlib-failures.test-sh
This is timing out in CI in some configurations.

rdar://78483379
2021-05-25 16:51:22 -07:00
Ben Langmuir
e42932ea54 Disable ModuleInterface/swift_build_sdk_interfaces/xfail-logs.test-sh
This is timing out in CI in some configurations.

rdar://78318467
2021-05-21 11:02:19 -07:00
Michael Gottesman
504b5f2058 [ossa][frontend] Separately namespace enable-ossa-modules in the prebuilt module cache so that the flag causes recompilation of imported resilient modules when the flag is enabled.
This will enable users to try out the '-enable-ossa-modules' flag if their
compiler supports it and get OSSA code on all inlinable code that they use. The
idea is that this is a nice way to stage this in and get more testing.

The specific implementation is that the module interface loader:

1. Knows if enable ossa modules is enabled not to search for any compiled
modules. We always rebuild from the interface file on the system.

2. Knows that if enable ossa modules is enabled to mixin a bit into the module
interface loader cache hash to ensure that we consider the specialized ossa
compiled modules to be different than the modules in that cache from the system.

This ensures that when said flag is enabled, the user transparently gets all
their code in OSSA form from transparent libraries.
2021-03-18 13:03:51 -07:00
Argyrios Kyrtzidis
a9f497d20c [utils/swift_build_sdk_interfaces.py] Remove passing '-track-system-dependencies' when prebuilding modules from the interfaces
Including all the system header dependencies and `stat`ing them all the time introduces significant performance overhead for normal compilation, and other features like code-completion, without being worth it in practice.
2020-10-21 17:12:23 -07:00
3405691582
62a13e9ecd [test] Erase SDKROOT since env -u is not portable.
The `env -u` flag is not portable and not available on all platforms, so
this unit test will fail when the feature is unavailable.  Instead of
trying to unset the field, just erase it instead, since trying to copy
the entire invoked environment is difficult.
2020-09-19 21:05:01 -04:00
Saleem Abdulrasool
e3548dd638 test: use -log-path for stderr access in ModuleInterface tests
The stderr handles seem to behave differently under Python 3.  Use the
`-log-path` option to capture the standard error output and validate the
output.
2020-07-09 17:19:55 +00:00
3405691582
c8ba437444 [test] Handle architecture aliasing for OpenBSD.
Swift calls the architecture x86_64, OpenBSD calls it amd64. If we use
run_cpu in lit.cfg as-is, then we may need to duplicate lines in each
test for 'x86_64' and 'amd64', which puts a maintenance burden on unit
test developers to ensure they are duplicating changes to each line.

Instead, alias 'amd64' to 'x86_64' for `run_cpu`, but keep the platform
module path referring to 'amd64', in order to distinguish the target
architecture name and the Swift architecture name. This is particularly
relevant for the %target-.*-name pseudovariables used, which should
reference the Swift architecture names.

However, some unit tests are directly referencing %target-cpu directly,
which would break the aliasing. This is done only for swiftinterface
files, so a new substitution is defined in lit.cfg for these variables,
and the affected unit test cases are migrated.
2020-06-12 21:06:37 -04:00
Brent Royal-Gordon
f7c4c9e920 Reduce path length of swift_build_sdk_interfaces Catalyst fixtures
#31342 moved a file to a path that’s too long for our Windows builders. Collapse the directory structure a bit to get it under the limit.
2020-04-28 20:42:24 -07:00
Varun Gandhi
a1716fe2a6 [Diagnostics] Update compiler diagnostics to use less jargon. (#31315)
Fixes rdar://problem/62375243.
2020-04-28 14:11:39 -07:00
Brent Royal-Gordon
0c54e2d6e0 Rename Mac Catalyst-related test
Fixes rdar://62338598
2020-04-27 12:02:49 -07:00
Doug Gregor
58296b9dab Update test for building module interfaces for an SDK 2020-04-23 21:33:36 -07:00
Robert Widmann
12d542c24f Specialize a test for Windows
An unfortunate workaround for rdar://59397376

Resolves rdar://59318361
2020-02-12 12:45:43 -08:00
Robert Widmann
6d40e7b350 XFAIL a test holding up the rebranch process 2020-02-10 11:24:15 -08:00
Saleem Abdulrasool
546c5b79ab tests: fix accidental not env usage
Manually expand out the few places where we had a `not ...` substitution
where the substituted value was invoking `env` to alter the environment.
This pattern is not portable and causes problems when using the
integrated shell, such as on Windows.  This was identified during the
LLVM update.

This additionally corrects the use of `not` to indicate that it is
expecting a crashing failure.  This was resulting in the Windows tests
failing as `not` was not expecting a crashing failure.
2020-01-14 13:29:14 -08:00
Harlan Haskins
d3b8ce7ae2 [test] Update ParseableInterface to ModuleInterface
Also remove uses of -emit-parseable-module-interface from tests
2019-09-13 14:55:48 -07:00