Skip to content

Commit 71b7131

Browse files
committed
Build compiler-validated bundles from latest branch commits, not older tags
Also update patches, particularly to disable failing tests from the compiler validation suite
1 parent 50ba1cd commit 71b7131

File tree

6 files changed

+112
-124
lines changed

6 files changed

+112
-124
lines changed

swift-ci/sdks/android/build-docker

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,15 @@ HOST_OS=ubuntu24.04
2626
source ./scripts/toolchain-vars.sh
2727

2828
# Check-out and patch the sources
29+
if [[ "${BUILD_COMPILER}" != "1" ]]; then
2930
./scripts/fetch-source.sh --source-dir ${WORKDIR}/source --swift-tag ${SWIFT_TAG}
31+
else
32+
if [[ "${BUILD_SCHEME}" == "development" ]]; then
33+
./scripts/fetch-source.sh --source-dir ${WORKDIR}/source --swift-scheme main
34+
else
35+
./scripts/fetch-source.sh --source-dir ${WORKDIR}/source --swift-scheme release/6.2
36+
fi
37+
fi
3038
./patches/apply-patches.sh ${WORKDIR}/source/swift-project
3139

3240
mkdir -p ${WORKDIR}/products

swift-ci/sdks/android/patches/apply-patches.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,11 @@ cd ${1}
66
case "${BUILD_SCHEME}" in
77
swift-*-branch)
88
git apply -v -C1 ${patches_dir}/swift-android.patch
9-
git apply -v -C1 ${patches_dir}/swift-android-testing-except-release.patch
9+
git apply -v -C1 ${patches_dir}/swift-android-devel.patch
1010
;;
1111
development)
1212
git apply -v -C1 ${patches_dir}/swift-android.patch
1313
git apply -v -C1 ${patches_dir}/swift-android-trunk-libdispatch.patch
14-
git apply -v -C1 ${patches_dir}/swift-android-testing-except-release.patch
1514
;;
1615
*)
1716
echo "$0: invalid BUILD_SCHEME=${BUILD_SCHEME}"

swift-ci/sdks/android/patches/swift-android-testing-except-release.patch renamed to swift-ci/sdks/android/patches/swift-android-devel.patch

Lines changed: 33 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,23 @@
1+
commit 2e87eb24f85f3e84bff78051fba4870a5c061ec0
2+
Author: finagolfin
3+
Date: Mon Jun 30 10:39:26 2025
4+
5+
[test] Fix or disable tests for 32-bit platforms (#82501)
6+
7+
Fix two IRGen tests that are failing on Android armv7 and disable eight ClangImporter, C++ Interop, and SILOptimizer tests, two of which that were already failing on other 32-bit platforms.
8+
19
diff --git a/swift/test/ClangImporter/pcm-emit-direct-cc1-mode.swift b/swift/test/ClangImporter/pcm-emit-direct-cc1-mode.swift
2-
index f5048b9e3d5..c227ef7b77d 100644
10+
index f5048b9e3d5..6bc26ca3177 100644
311
--- a/swift/test/ClangImporter/pcm-emit-direct-cc1-mode.swift
412
+++ b/swift/test/ClangImporter/pcm-emit-direct-cc1-mode.swift
5-
@@ -9,7 +9,7 @@
6-
// CHECK-DUMP: Module map file: {{.*[/\\]}}Inputs{{/|\\}}custom-modules{{/|\\}}module.modulemap
7-
8-
// Verify that the clang command-line used is cc1
9-
-// RUN: %FileCheck -check-prefix CHECK-CLANG -DTRIPLE=%target-triple %s < %t.diags.txt
10-
+// RUN: %FileCheck -check-prefix CHECK-CLANG -DTRIPLE=%module-target-triple %s < %t.diags.txt
11-
// CHECK-CLANG: clang importer cc1 args
12-
// CHECK-CLANG-SAME: '-o' '{{.*[/\\]}}script.pcm' '-fsyntax-only' '-x' 'objective-c' '{{.*[/\\]}}module.modulemap' '-triple' '[[TRIPLE]]'
13+
@@ -15,5 +15,7 @@
1314
// CHECK-CLANG-SAME: '-fmodules'
15+
// CHECK-CLANG-NOT: clang importer driver args
16+
17+
+// XFAIL: OS=linux-androideabi
18+
+
19+
import script
20+
var _ : ScriptTy
1421
diff --git a/swift/test/IRGen/abitypes_arm.swift b/swift/test/IRGen/abitypes_arm.swift
1522
index 9428294483d..52bd8b10145 100644
1623
--- a/swift/test/IRGen/abitypes_arm.swift
@@ -111,6 +118,23 @@ index f7f2664b2de..01d36e127c6 100644
111118

112119
// CHECK-DISABLED-NOT: normal_count
113120

121+
diff --git a/swift/utils/swift_build_support/swift_build_support/cmake.py b/swift/utils/swift_build_support/swift_build_support/cmake.py
122+
index bfb69965890..b5e9f5349c2 100644
123+
--- a/swift/utils/swift_build_support/swift_build_support/cmake.py
124+
+++ b/swift/utils/swift_build_support/swift_build_support/cmake.py
125+
@@ -153,10 +153,8 @@ class CMake(object):
126+
toolchain_path = product.native_toolchain_path(args.host_target)
127+
cmake_swiftc_path = os.getenv('CMAKE_Swift_COMPILER',
128+
os.path.join(toolchain_path, 'bin', 'swiftc'))
129+
- define("CMAKE_C_COMPILER:PATH", os.path.join(toolchain_path,
130+
- 'bin', 'clang'))
131+
- define("CMAKE_CXX_COMPILER:PATH", os.path.join(toolchain_path,
132+
- 'bin', 'clang++'))
133+
+ define("CMAKE_C_COMPILER:PATH", toolchain.cc)
134+
+ define("CMAKE_CXX_COMPILER:PATH", toolchain.cxx)
135+
define("CMAKE_Swift_COMPILER:PATH", cmake_swiftc_path)
136+
else:
137+
cmake_swiftc_path = os.getenv('CMAKE_Swift_COMPILER', toolchain.swiftc)
114138
diff --git a/swift/utils/swift_build_support/swift_build_support/products/product.py b/swift/utils/swift_build_support/swift_build_support/products/product.py
115139
index 274b6037305..bf0f7fcf671 100644
116140
--- a/swift/utils/swift_build_support/swift_build_support/products/product.py
@@ -124,33 +148,3 @@ index 274b6037305..bf0f7fcf671 100644
124148
install_destdir = os.path.join(install_destdir, self.args.host_target)
125149
return targets.toolchain_path(install_destdir,
126150
self.args.install_prefix)
127-
diff --git a/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake b/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
128-
index 468dc61..a90ae3d 100644
129-
--- a/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
130-
+++ b/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
131-
@@ -2,6 +2,10 @@
132-
set(print_target_info_invocation "${CMAKE_Swift_COMPILER}" -print-target-info)
133-
if(CMAKE_Swift_COMPILER_TARGET)
134-
list(APPEND print_target_info_invocation -target ${CMAKE_Swift_COMPILER_TARGET})
135-
+else()
136-
+ set(arg_list ${CMAKE_Swift_FLAGS})
137-
+ separate_arguments(arg_list)
138-
+ list(APPEND print_target_info_invocation ${arg_list})
139-
endif()
140-
execute_process(COMMAND ${print_target_info_invocation} OUTPUT_VARIABLE target_info_json)
141-
message(CONFIGURE_LOG "Swift Target Info: ${print_target_info_invocation}\n"
142-
diff --git a/swift-testing/cmake/modules/PlatformInfo.cmake b/swift-testing/cmake/modules/PlatformInfo.cmake
143-
index 94c60ef..ab8a491 100644
144-
--- a/swift-testing/cmake/modules/PlatformInfo.cmake
145-
+++ b/swift-testing/cmake/modules/PlatformInfo.cmake
146-
@@ -9,6 +9,10 @@
147-
set(print_target_info_invocation "${CMAKE_Swift_COMPILER}" -print-target-info)
148-
if(CMAKE_Swift_COMPILER_TARGET)
149-
list(APPEND print_target_info_invocation -target ${CMAKE_Swift_COMPILER_TARGET})
150-
+else()
151-
+ set(arg_list ${CMAKE_Swift_FLAGS})
152-
+ separate_arguments(arg_list)
153-
+ list(APPEND print_target_info_invocation ${arg_list})
154-
endif()
155-
execute_process(COMMAND ${print_target_info_invocation} OUTPUT_VARIABLE target_info_json)
156-
message(CONFIGURE_LOG "Swift Target Info: ${print_target_info_invocation}\n"

swift-ci/sdks/android/patches/swift-android-testing-release.patch

Lines changed: 0 additions & 61 deletions
This file was deleted.

swift-ci/sdks/android/patches/swift-android-trunk-libdispatch.patch

Lines changed: 16 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -10,30 +10,24 @@ index 3f36fc979cb..8713ae8fea8 100755
1010
"grep",
1111
"--extended-regexp",
1212
"--recursive",
13-
diff --git a/swift/test/Reflection/conformance_descriptors.swift b/swift/test/Reflection/conformance_descriptors.swift
14-
index b114f764552..e1bd98c08f4 100644
15-
--- a/swift/test/Reflection/conformance_descriptors.swift
16-
+++ b/swift/test/Reflection/conformance_descriptors.swift
17-
@@ -5,6 +5,7 @@
18-
//
19-
// Temporarily disable on AArch64 Linux (rdar://88451721)
20-
// UNSUPPORTED: OS=linux-gnu && CPU=aarch64
21-
+// XFAIL: OS=linux-android
13+
diff --git a/swift/utils/swift_build_support/swift_build_support/cmake.py b/swift/utils/swift_build_support/swift_build_support/cmake.py
14+
index 9a0f5b43e2d..5c7d1320a2d 100644
15+
--- a/swift/utils/swift_build_support/swift_build_support/cmake.py
16+
+++ b/swift/utils/swift_build_support/swift_build_support/cmake.py
17+
@@ -150,11 +150,8 @@ class CMake(object):
18+
define("CMAKE_CXX_COMPILER_LAUNCHER:PATH", args.cmake_cxx_launcher)
2219

23-
// rdar://100558042
24-
// UNSUPPORTED: CPU=arm64e
25-
diff --git a/swift/test/Reflection/typeref_decoding.swift b/swift/test/Reflection/typeref_decoding.swift
26-
index e0a3b4465a3..c01af893eda 100644
27-
--- a/swift/test/Reflection/typeref_decoding.swift
28-
+++ b/swift/test/Reflection/typeref_decoding.swift
29-
@@ -10,6 +10,7 @@
20+
if self.prefer_native_toolchain and product:
21+
- clang_tools_path = product.native_clang_tools_path(args.host_target)
22+
- define("CMAKE_C_COMPILER:PATH", os.path.join(clang_tools_path,
23+
- 'bin', 'clang'))
24+
- define("CMAKE_CXX_COMPILER:PATH", os.path.join(clang_tools_path,
25+
- 'bin', 'clang++'))
26+
+ define("CMAKE_C_COMPILER:PATH", toolchain.cc)
27+
+ define("CMAKE_CXX_COMPILER:PATH", toolchain.cxx)
3028

31-
// FIXME: rdar://127796117
32-
// UNSUPPORTED: OS=linux-gnu && CPU=aarch64
33-
+// XFAIL: OS=linux-android
34-
35-
// RUN: %target-build-swift -target %target-swift-5.2-abi-triple -Xfrontend -enable-anonymous-context-mangled-names %S/Inputs/ConcreteTypes.swift %S/Inputs/GenericTypes.swift %S/Inputs/Protocols.swift %S/Inputs/Extensions.swift %S/Inputs/Closures.swift -parse-as-library -emit-module -emit-library %no-fixup-chains -module-name TypesToReflect -o %t/%target-library-name(TypesToReflect)
36-
// RUN: %target-build-swift -target %target-swift-5.2-abi-triple -Xfrontend -enable-anonymous-context-mangled-names %S/Inputs/ConcreteTypes.swift %S/Inputs/GenericTypes.swift %S/Inputs/Protocols.swift %S/Inputs/Extensions.swift %S/Inputs/Closures.swift %S/Inputs/main.swift -emit-module -emit-executable %no-fixup-chains -module-name TypesToReflect -o %t/TypesToReflect
29+
toolchain_path = product.native_toolchain_path(args.host_target)
30+
cmake_swiftc_path = os.getenv('CMAKE_Swift_COMPILER',
3731
diff --git a/swift-corelibs-libdispatch/cmake/modules/SwiftSupport.cmake b/swift-corelibs-libdispatch/cmake/modules/SwiftSupport.cmake
3832
index 3da519e..e2dd8ed 100644
3933
--- a/swift-corelibs-libdispatch/cmake/modules/SwiftSupport.cmake

swift-ci/sdks/android/patches/swift-android.patch

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
diff --git a/swift/test/SILOptimizer/concat_string_literals.32.swift b/swift/test/SILOptimizer/concat_string_literals.32.swift
2+
index 01390761c8c..d84c142397c 100644
3+
--- a/swift/test/SILOptimizer/concat_string_literals.32.swift
4+
+++ b/swift/test/SILOptimizer/concat_string_literals.32.swift
5+
@@ -4,6 +4,7 @@
6+
7+
// We have a separate test for 64-bit architectures.
8+
// REQUIRES: PTRSIZE=32
9+
+// XFAIL: OS=linux-androideabi
10+
11+
// NOTE: 25185.byteSwapped = 0x62 'a', 0x61 'b'
12+
// CHECK-LABEL: test_ascii_scalar_scalar2
13+
diff --git a/swift/test/SILOptimizer/semantic-arc-opts-redundantcopyopts.sil b/swift/test/SILOptimizer/semantic-arc-opts-redundantcopyopts.sil
14+
index 98765e0e4a3..4dc68bf522b 100644
15+
--- a/swift/test/SILOptimizer/semantic-arc-opts-redundantcopyopts.sil
16+
+++ b/swift/test/SILOptimizer/semantic-arc-opts-redundantcopyopts.sil
17+
@@ -1,5 +1,7 @@
18+
// RUN: %target-sil-opt -module-name Swift -enable-sil-verify-all -semantic-arc-opts -sil-semantic-arc-peepholes-redundant-copyvalue-elim %s | %FileCheck %s
19+
20+
+// XFAIL: OS=linux-android, OS=linux-androideabi
21+
+
22+
// NOTE: Some of our tests here depend on borrow elimination /not/ running!
23+
// Please do not add it to clean up the IR like we did in
24+
// semanticarcopts-loadcopy-to-loadborrow!
125
diff --git a/swift/utils/build-script-impl b/swift/utils/build-script-impl
226
index 16e05052609..7ab8cebfab8 100755
327
--- a/swift/utils/build-script-impl
@@ -59,6 +83,21 @@ index 7f290d16..95366592 100644
5983
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
6084
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
6185
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
86+
diff --git a/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake b/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
87+
index 468dc61..a90ae3d 100644
88+
--- a/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
89+
+++ b/swift-corelibs-xctest/cmake/modules/PlatformInfo.cmake
90+
@@ -2,6 +2,10 @@
91+
set(print_target_info_invocation "${CMAKE_Swift_COMPILER}" -print-target-info)
92+
if(CMAKE_Swift_COMPILER_TARGET)
93+
list(APPEND print_target_info_invocation -target ${CMAKE_Swift_COMPILER_TARGET})
94+
+else()
95+
+ set(arg_list ${CMAKE_Swift_FLAGS})
96+
+ separate_arguments(arg_list)
97+
+ list(APPEND print_target_info_invocation ${arg_list})
98+
endif()
99+
execute_process(COMMAND ${print_target_info_invocation} OUTPUT_VARIABLE target_info_json)
100+
message(CONFIGURE_LOG "Swift Target Info: ${print_target_info_invocation}\n"
62101
diff --git a/swift-foundation/cmake/modules/SwiftFoundationSwiftSupport.cmake b/swift-foundation/cmake/modules/SwiftFoundationSwiftSupport.cmake
63102
index cbdfc2a..bb4121d 100644
64103
--- a/swift-foundation/cmake/modules/SwiftFoundationSwiftSupport.cmake
@@ -86,6 +125,21 @@ index 1be9a4b..bd7b1bd 100644
86125
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
87126
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
88127
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
128+
diff --git a/swift-testing/cmake/modules/PlatformInfo.cmake b/swift-testing/cmake/modules/PlatformInfo.cmake
129+
index 94c60ef..ab8a491 100644
130+
--- a/swift-testing/cmake/modules/PlatformInfo.cmake
131+
+++ b/swift-testing/cmake/modules/PlatformInfo.cmake
132+
@@ -9,6 +9,10 @@
133+
set(print_target_info_invocation "${CMAKE_Swift_COMPILER}" -print-target-info)
134+
if(CMAKE_Swift_COMPILER_TARGET)
135+
list(APPEND print_target_info_invocation -target ${CMAKE_Swift_COMPILER_TARGET})
136+
+else()
137+
+ set(arg_list ${CMAKE_Swift_FLAGS})
138+
+ separate_arguments(arg_list)
139+
+ list(APPEND print_target_info_invocation ${arg_list})
140+
endif()
141+
execute_process(COMMAND ${print_target_info_invocation} OUTPUT_VARIABLE target_info_json)
142+
message(CONFIGURE_LOG "Swift Target Info: ${print_target_info_invocation}\n"
89143
diff --git a/swift-testing/cmake/modules/TargetTriple.cmake b/swift-testing/cmake/modules/TargetTriple.cmake
90144
index e087cc4..02f3a95 100644
91145
--- a/swift-testing/cmake/modules/TargetTriple.cmake

0 commit comments

Comments
 (0)