Skip to content

Commit 1bf4702

Browse files
authored
Disable prctl test when building for arm or riscv. (#143627)
I'm setting up a buildbot for arm32 using qemu and qemu doesn't support PR_GET_THP_DISABLE. Disable the test for now while we figure out what to do about that. Also disable for riscv because we may do the same for riscv buildbots.
1 parent 48122a7 commit 1bf4702

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

libc/test/src/sys/prctl/linux/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
add_custom_target(libc_sys_prctl_unittests)
22

3+
# Temporarily disable this test while setting up arm and riscv buildbots
4+
# using qemu, since PR_GET_THP_DISABLE is not supported on qemu.
5+
if (NOT (LIBC_TARGET_ARCHITECTURE_IS_ARM OR
6+
LIBC_TARGET_ARCHITECTURE_IS_RISCV32 OR
7+
LIBC_TARGET_ARCHITECTURE_IS_RISCV64))
38
add_libc_unittest(
49
prctl_test
510
SUITE
@@ -13,3 +18,4 @@ add_libc_unittest(
1318
libc.test.UnitTest.ErrnoCheckingTest
1419
libc.test.UnitTest.ErrnoSetterMatcher
1520
)
21+
endif()

libc/test/src/sys/prctl/linux/prctl_test.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ TEST_F(LlvmLibcSysPrctlTest, GetSetName) {
3434
TEST_F(LlvmLibcSysPrctlTest, GetTHPDisable) {
3535
// Manually check errno since the return value logic here is not
3636
// covered in ErrnoSetterMatcher.
37+
// Note that PR_GET_THP_DISABLE is not supported by QEMU.
3738
int ret = LIBC_NAMESPACE::prctl(PR_GET_THP_DISABLE, 0, 0, 0, 0);
3839
ASSERT_ERRNO_SUCCESS();
3940
// PR_GET_THP_DISABLE return (as the function result) the current

0 commit comments

Comments
 (0)