summaryrefslogtreecommitdiffstats
path: root/tools/build/feature/test-llvm-perf.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/build/feature/test-llvm-perf.cpp')
-rw-r--r--tools/build/feature/test-llvm-perf.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/tools/build/feature/test-llvm-perf.cpp b/tools/build/feature/test-llvm-perf.cpp
new file mode 100644
index 000000000000..a8cbb67e335e
--- /dev/null
+++ b/tools/build/feature/test-llvm-perf.cpp
@@ -0,0 +1,14 @@
+// SPDX-License-Identifier: GPL-2.0
+#include "llvm/Support/ManagedStatic.h"
+#include "llvm/Support/raw_ostream.h"
+
+#if LLVM_VERSION_MAJOR < 13
+# error "Perf requires llvm-devel/llvm-dev version 13 or greater"
+#endif
+
+int main()
+{
+ llvm::errs() << "Hello World!\n";
+ llvm::llvm_shutdown();
+ return 0;
+}