summaryrefslogtreecommitdiffstats
path: root/llvm/benchmarks/DummyYAML.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/benchmarks/DummyYAML.cpp')
-rw-r--r--llvm/benchmarks/DummyYAML.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/llvm/benchmarks/DummyYAML.cpp b/llvm/benchmarks/DummyYAML.cpp
new file mode 100644
index 00000000000..c06b001bb03
--- /dev/null
+++ b/llvm/benchmarks/DummyYAML.cpp
@@ -0,0 +1,13 @@
+#include "benchmark/benchmark.h"
+#include "llvm/Support/YAMLTraits.h"
+
+static void BM_YAMLDummyIsNumeric(benchmark::State& state) {
+ std::string x = "hello";
+ for (auto _ : state) {
+ std::string copy(x);
+ llvm::yaml::isNumeric(copy);
+ }
+}
+BENCHMARK(BM_YAMLDummyIsNumeric);
+
+BENCHMARK_MAIN();
OpenPOWER on IntegriCloud