Skip to content

Commit 67f509a

Browse files
rorthtru
authored andcommitted
[sanitizer_common][test] Always skip select allocator tests on SPARC V9 (#100530)
Two allocator tests `FAIL` on Linux/sparc64: ``` SanitizerCommon-Unit :: ./Sanitizer-sparcv9-Test/SanitizerCommon/CombinedAllocator32Compact SanitizerCommon-Unit :: ./Sanitizer-sparcv9-Test/SanitizerCommon/SizeClassAllocator32Iteration ``` The failure mode is the same on Solaris/sparcv9, where those tests are already disabled since 0f69cbe. Therefore, this patch skips them on SPARC in general. Tested on `sparc64-unknown-linux-gnu` and `sparcv9-sun-solaris2.11`. (cherry picked from commit 3d14912)
1 parent 146fc62 commit 67f509a

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

compiler-rt/lib/sanitizer_common/tests/sanitizer_allocator_test.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,13 @@
2828

2929
using namespace __sanitizer;
3030

31-
#if SANITIZER_SOLARIS && defined(__sparcv9)
31+
#if defined(__sparcv9)
3232
// FIXME: These tests probably fail because Solaris/sparcv9 uses the full
33-
// 64-bit address space. Needs more investigation
34-
#define SKIP_ON_SOLARIS_SPARCV9(x) DISABLED_##x
33+
// 64-bit address space. Same on Linux/sparc64, so probably a general SPARC
34+
// issue. Needs more investigation
35+
# define SKIP_ON_SPARCV9(x) DISABLED_##x
3536
#else
36-
#define SKIP_ON_SOLARIS_SPARCV9(x) x
37+
# define SKIP_ON_SPARCV9(x) x
3738
#endif
3839

3940
// On 64-bit systems with small virtual address spaces (e.g. 39-bit) we can't
@@ -781,7 +782,7 @@ TEST(SanitizerCommon, CombinedAllocator64VeryCompact) {
781782
}
782783
#endif
783784

784-
TEST(SanitizerCommon, SKIP_ON_SOLARIS_SPARCV9(CombinedAllocator32Compact)) {
785+
TEST(SanitizerCommon, SKIP_ON_SPARCV9(CombinedAllocator32Compact)) {
785786
TestCombinedAllocator<Allocator32Compact>();
786787
}
787788

@@ -1028,7 +1029,7 @@ TEST(SanitizerCommon, SizeClassAllocator64DynamicPremappedIteration) {
10281029
#endif
10291030
#endif
10301031

1031-
TEST(SanitizerCommon, SKIP_ON_SOLARIS_SPARCV9(SizeClassAllocator32Iteration)) {
1032+
TEST(SanitizerCommon, SKIP_ON_SPARCV9(SizeClassAllocator32Iteration)) {
10321033
TestSizeClassAllocatorIteration<Allocator32Compact>();
10331034
}
10341035

0 commit comments

Comments
 (0)