Skip to content

Commit 61da472

Browse files
authored
Remove armv4t/armv5t from check-all targets (#540)
The picolibc, compiler-rt and libcxx tests for armv4t and armv5t variants currently hang until a timeout is reached. Rather than disable the tests, this patch removes them from the check-all targets. This allows the tests to still be run while investigating the issue, but does not interrupt overall testing of the toolchain.
1 parent d8d3fd2 commit 61da472

File tree

3 files changed

+127
-5
lines changed

3 files changed

+127
-5
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
From 8e51f55289eef78b08edb845023c1a7c9c0191b5 Mon Sep 17 00:00:00 2001
2+
From: David Candler <[email protected]>
3+
Date: Wed, 23 Oct 2024 14:40:58 +0100
4+
Subject: [PATCH] Remove armv4t/armv5t from check-all targets
5+
6+
The compiler-rt and libcxx tests for armv4t and armv5t variants
7+
currently hang until a timeout is reached. Rather than disable the
8+
tests, this patch removes them from the check-all targets. This
9+
allows the tests to still be run while investigating the issue, but
10+
does not interrupt overall testing of the toolchain.
11+
---
12+
CMakeLists.txt | 18 +++++++++++++++---
13+
1 file changed, 15 insertions(+), 3 deletions(-)
14+
15+
diff --git a/CMakeLists.txt b/CMakeLists.txt
16+
index 60ec6c6..fa5b462 100644
17+
--- a/CMakeLists.txt
18+
+++ b/CMakeLists.txt
19+
@@ -1310,7 +1310,11 @@ function(add_compiler_rt_tests variant)
20+
)
21+
add_custom_target(check-compiler-rt-${variant})
22+
add_dependencies(check-compiler-rt-${variant} compiler_rt_${variant}-check-compiler-rt)
23+
- add_dependencies(check-compiler-rt check-compiler-rt-${variant})
24+
+ # Do not add armv4 or armv5 tests to the check-all
25+
+ # targets as they currently hang.
26+
+ if(NOT VARIANT_COMPILE_FLAGS MATCHES "-march=armv4|5")
27+
+ add_dependencies(check-compiler-rt check-compiler-rt-${variant})
28+
+ endif()
29+
add_dependencies(check-llvm-toolchain-runtimes-${variant} check-compiler-rt-${variant})
30+
endfunction()
31+
32+
@@ -1334,7 +1338,11 @@ function(add_libcxx_libcxxabi_libunwind_tests variant)
33+
)
34+
add_custom_target(${check_target}-${variant_with_extensions})
35+
add_dependencies(${check_target}-${variant_with_extensions} ${target_name}-${check_target})
36+
- add_dependencies(${check_target} ${target_name}-${check_target})
37+
+ # Do not add armv4 or armv5 tests to the check-all
38+
+ # targets as they currently hang.
39+
+ if(NOT variant MATCHES "-march=armv4|5")
40+
+ add_dependencies(${check_target} ${target_name}-${check_target})
41+
+ endif()
42+
add_dependencies(check-llvm-toolchain-runtimes-${variant} ${check_target}-${variant_with_extensions})
43+
endforeach()
44+
endfunction()
45+
@@ -1499,7 +1507,11 @@ function(add_library_variant target_arch)
46+
message("C++ runtime libraries tests disabled for ${variant}")
47+
else()
48+
add_custom_target(check-llvm-toolchain-runtimes-${variant})
49+
- add_dependencies(check-llvm-toolchain-runtimes check-llvm-toolchain-runtimes-${variant})
50+
+ # Do not add armv4 or armv5 tests to the check-all
51+
+ # targets as they currently hang.
52+
+ if(NOT VARIANT_COMPILE_FLAGS MATCHES "-march=armv4|5")
53+
+ add_dependencies(check-llvm-toolchain-runtimes check-llvm-toolchain-runtimes-${variant})
54+
+ endif()
55+
add_compiler_rt_tests("${variant}")
56+
if(CXX_LIBS)
57+
add_libcxx_libcxxabi_libunwind_tests("${variant}")
58+
--
59+
2.34.1
60+
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
From 2f9a405df7f3e211eab7bb44dcb3a5b3b88665d8 Mon Sep 17 00:00:00 2001
2+
From: David Candler <[email protected]>
3+
Date: Thu, 24 Oct 2024 10:07:57 +0100
4+
Subject: [PATCH] Update picolibc patch file
5+
6+
Patch no longer cleanly applies, so this updates the diff.
7+
---
8+
patches/picolibc.patch | 12 ++++++------
9+
1 file changed, 6 insertions(+), 6 deletions(-)
10+
11+
diff --git a/patches/picolibc.patch b/patches/picolibc.patch
12+
index ba5b17a..a77d879 100644
13+
--- a/patches/picolibc.patch
14+
+++ b/patches/picolibc.patch
15+
@@ -1,8 +1,8 @@
16+
diff --git a/meson.build b/meson.build
17+
-index 0fdfa0412..8e679f166 100644
18+
+index f90f5b818..2f8d63733 100644
19+
--- a/meson.build
20+
+++ b/meson.build
21+
-@@ -1224,6 +1224,18 @@ if get_option('newlib-retargetable-locking') != get_option('newlib-multithread')
22+
+@@ -1310,6 +1310,18 @@ if get_option('newlib-retargetable-locking') != get_option('newlib-multithread')
23+
error('newlib-retargetable-locking and newlib-multithread must be set to the same value')
24+
endif
25+
26+
@@ -22,13 +22,13 @@ index 0fdfa0412..8e679f166 100644
27+
cc.has_argument('-fno-tree-loop-distribute-patterns'),
28+
description: 'Compiler flag to prevent detecting memcpy/memset patterns')
29+
diff --git a/picolibc.ld.in b/picolibc.ld.in
30+
-index b97ea3300..04b94f35c 100644
31+
+index 7b63ba172..cda5e1e7e 100644
32+
--- a/picolibc.ld.in
33+
+++ b/picolibc.ld.in
34+
@@ -68,6 +68,9 @@ SECTIONS
35+
- *(.text.unlikely .text.unlikely.*)
36+
- *(.text.startup .text.startup.*)
37+
- *(.text .text.* .opd .opd.*)
38+
+ *(.literal.unlikely .text.unlikely .literal.unlikely.* .text.unlikely.*)
39+
+ *(.literal.startup .text.startup .literal.startup.* .text.startup.*)
40+
+ *(.literal .text .literal.* .text.* .opd .opd.*)
41+
+ PROVIDE (__start___lcxx_override = .);
42+
+ *(__lcxx_override)
43+
+ PROVIDE (__stop___lcxx_override = .);
44+
--
45+
2.34.1
46+

CMakeLists.txt

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -804,8 +804,12 @@ function(
804804
if(run_tests)
805805
add_custom_target(check-picolibc-${variant})
806806
add_dependencies(check-picolibc-${variant} picolibc_${variant}-test)
807-
add_dependencies(check-picolibc check-picolibc-${variant})
808-
add_dependencies(llvm-toolchain-runtimes picolibc_${variant})
807+
# Do not add armv4 or armv5 tests to the check-all
808+
# targets as they currently hang.
809+
if(NOT variant MATCHES "armv4|5")
810+
add_dependencies(check-picolibc check-picolibc-${variant})
811+
add_dependencies(llvm-toolchain-runtimes picolibc_${variant})
812+
endif()
809813
endif()
810814
endfunction()
811815

@@ -1310,7 +1314,11 @@ function(add_compiler_rt_tests variant)
13101314
)
13111315
add_custom_target(check-compiler-rt-${variant})
13121316
add_dependencies(check-compiler-rt-${variant} compiler_rt_${variant}-check-compiler-rt)
1313-
add_dependencies(check-compiler-rt check-compiler-rt-${variant})
1317+
# Do not add armv4 or armv5 tests to the check-all
1318+
# targets as they currently hang.
1319+
if(NOT variant MATCHES "armv4|5")
1320+
add_dependencies(check-compiler-rt check-compiler-rt-${variant})
1321+
endif()
13141322
add_dependencies(check-llvm-toolchain-runtimes-${variant} check-compiler-rt-${variant})
13151323
endfunction()
13161324

@@ -1334,7 +1342,11 @@ function(add_libcxx_libcxxabi_libunwind_tests variant)
13341342
)
13351343
add_custom_target(${check_target}-${variant_with_extensions})
13361344
add_dependencies(${check_target}-${variant_with_extensions} ${target_name}-${check_target})
1337-
add_dependencies(${check_target} ${target_name}-${check_target})
1345+
# Do not add armv4 or armv5 tests to the check-all
1346+
# targets as they currently hang.
1347+
if(NOT variant MATCHES "armv4|5")
1348+
add_dependencies(${check_target} ${target_name}-${check_target})
1349+
endif()
13381350
add_dependencies(check-llvm-toolchain-runtimes-${variant} ${check_target}-${variant_with_extensions})
13391351
endforeach()
13401352
endfunction()
@@ -1499,7 +1511,11 @@ function(add_library_variant target_arch)
14991511
message("C++ runtime libraries tests disabled for ${variant}")
15001512
else()
15011513
add_custom_target(check-llvm-toolchain-runtimes-${variant})
1502-
add_dependencies(check-llvm-toolchain-runtimes check-llvm-toolchain-runtimes-${variant})
1514+
# Do not add armv4 or armv5 tests to the check-all
1515+
# targets as they currently hang.
1516+
if(NOT variant MATCHES "armv4|5")
1517+
add_dependencies(check-llvm-toolchain-runtimes check-llvm-toolchain-runtimes-${variant})
1518+
endif()
15031519
add_compiler_rt_tests("${variant}")
15041520
if(CXX_LIBS)
15051521
add_libcxx_libcxxabi_libunwind_tests("${variant}")

0 commit comments

Comments
 (0)