From a4845eaf2e9aa18dd900d7cbeff4e5ff52e4b50e Mon Sep 17 00:00:00 2001 From: Leandro Lupori Date: Wed, 7 Jun 2023 17:27:59 +0000 Subject: [PATCH] [InstrProf] Skip Balanced Partitioning tests on ARM Balanced Partitioning tests, added by 1794532bb942, currently hang on ARM, what causes check-all to never finish. Issue #63168 Differential Revision: https://reviews.llvm.org/D147812 --- llvm/test/tools/llvm-profdata/show-order.proftext | 2 ++ llvm/unittests/Support/BalancedPartitioningTest.cpp | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/llvm/test/tools/llvm-profdata/show-order.proftext b/llvm/test/tools/llvm-profdata/show-order.proftext index 8ef26847ad77..1b80677d5d06 100644 --- a/llvm/test/tools/llvm-profdata/show-order.proftext +++ b/llvm/test/tools/llvm-profdata/show-order.proftext @@ -1,4 +1,6 @@ # RUN: llvm-profdata order %s | FileCheck %s +# PR63168: Balanced Partitioning tests currently hang on ARM. +# UNSUPPORTED: target=arm{{.*}} # CHECK: a # CHECK: b diff --git a/llvm/unittests/Support/BalancedPartitioningTest.cpp b/llvm/unittests/Support/BalancedPartitioningTest.cpp index ebe518a8e89c..05f7411b4327 100644 --- a/llvm/unittests/Support/BalancedPartitioningTest.cpp +++ b/llvm/unittests/Support/BalancedPartitioningTest.cpp @@ -17,6 +17,13 @@ using testing::Not; using testing::UnorderedElementsAre; using testing::UnorderedElementsAreArray; +// PR63168: Balanced Partitioning tests currently hang on ARM. +#if defined(__arm__) +#define SKIP_UNSUPPORTED_PLATFORM GTEST_SKIP() +#else +#define SKIP_UNSUPPORTED_PLATFORM do { } while(0) +#endif + namespace llvm { void PrintTo(const BPFunctionNode &Node, std::ostream *OS) { @@ -40,6 +47,7 @@ protected: }; TEST_F(BalancedPartitioningTest, Basic) { + SKIP_UNSUPPORTED_PLATFORM; std::vector Nodes = { BPFunctionNode(0, {1, 2}), BPFunctionNode(2, {3, 4}), BPFunctionNode(1, {1, 2}), BPFunctionNode(3, {3, 4}), @@ -59,6 +67,7 @@ TEST_F(BalancedPartitioningTest, Basic) { } TEST_F(BalancedPartitioningTest, Large) { + SKIP_UNSUPPORTED_PLATFORM; const int ProblemSize = 1000; std::vector AllUNs; for (int i = 0; i < ProblemSize; i++) @@ -85,6 +94,7 @@ TEST_F(BalancedPartitioningTest, Large) { } TEST_F(BalancedPartitioningTest, MoveGain) { + SKIP_UNSUPPORTED_PLATFORM; BalancedPartitioning::SignaturesT Signatures = { {10, 10, 10.f, 0.f, true}, // 0 {10, 10, 0.f, 10.f, true}, // 1