[llvm] 7b3f6e6 - [llvm-exegesis] Fix in SubprocessMemoryTest after commit adb01dea6a5
Bjorn Pettersson via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 8 13:49:47 PDT 2023
Author: Bjorn Pettersson
Date: 2023-09-08T22:49:33+02:00
New Revision: 7b3f6e64a0636fab9924afae5ba23f61adfac990
URL: https://github.com/llvm/llvm-project/commit/7b3f6e64a0636fab9924afae5ba23f61adfac990
DIFF: https://github.com/llvm/llvm-project/commit/7b3f6e64a0636fab9924afae5ba23f61adfac990.diff
LOG: [llvm-exegesis] Fix in SubprocessMemoryTest after commit adb01dea6a5
Make sure the TestCount const definition is guarded the same way
as the use of the constant.
This is an attempt to fix buildbot failures related to
-Wunused-const-variable.
Added:
Modified:
llvm/unittests/tools/llvm-exegesis/X86/SubprocessMemoryTest.cpp
Removed:
################################################################################
diff --git a/llvm/unittests/tools/llvm-exegesis/X86/SubprocessMemoryTest.cpp b/llvm/unittests/tools/llvm-exegesis/X86/SubprocessMemoryTest.cpp
index 27162cd335487f3..c07ec188a602c44 100644
--- a/llvm/unittests/tools/llvm-exegesis/X86/SubprocessMemoryTest.cpp
+++ b/llvm/unittests/tools/llvm-exegesis/X86/SubprocessMemoryTest.cpp
@@ -20,15 +20,15 @@
#include <unistd.h>
#endif // __linux__
-// This needs to be updated anytime a test is added or removed from the test
-// suite.
-static constexpr const size_t TestCount = 4;
-
namespace llvm {
namespace exegesis {
#if defined(__linux__) && !defined(__ANDROID__)
+// This needs to be updated anytime a test is added or removed from the test
+// suite.
+static constexpr const size_t TestCount = 4;
+
class SubprocessMemoryTest : public X86TestBase {
protected:
int getSharedMemoryNumber(const unsigned TestNumber) {
More information about the llvm-commits
mailing list