[PATCH] D35672: [XRay] [test-suite] Don't use llvm_multisource macro for XRay tests and use .test files
Eizan Miyamoto via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 3 06:06:24 PDT 2017
eizan updated this revision to Diff 109531.
eizan added a comment.
- Replace add_executable() with llvm_test_run() in XRay CMakeLists.txt
https://reviews.llvm.org/D35672
Files:
MicroBenchmarks/XRay/CMakeLists.txt
MicroBenchmarks/XRay/retref-bench_BM_RDTSCP_Cost.test
MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatched.test
MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedThenUnpatched.test
MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedWithLogHandler.test
MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedUnPatched.test
MicroBenchmarks/XRay/retref-bench_BM_ReturnNeverInstrumented.test
Index: MicroBenchmarks/XRay/retref-bench_BM_ReturnNeverInstrumented.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_ReturnNeverInstrumented.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_ReturnNeverInstrumented
Index: MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedUnPatched.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedUnPatched.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_ReturnInstrumentedUnPatched
Index: MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedWithLogHandler.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedWithLogHandler.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_ReturnInstrumentedPatchedWithLogHandler
Index: MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedThenUnpatched.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatchedThenUnpatched.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_ReturnInstrumentedPatchedThenUnpatched
Index: MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatched.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_ReturnInstrumentedPatched.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_ReturnInstrumentedPatched
Index: MicroBenchmarks/XRay/retref-bench_BM_RDTSCP_Cost.test
===================================================================
--- /dev/null
+++ MicroBenchmarks/XRay/retref-bench_BM_RDTSCP_Cost.test
@@ -0,0 +1 @@
+RUN: %S/retref-bench --benchmark_repetitions=10 --benchmark_report_aggregates_only=true --benchmark_filter=BM_RDTSCP_Cost
Index: MicroBenchmarks/XRay/CMakeLists.txt
===================================================================
--- MicroBenchmarks/XRay/CMakeLists.txt
+++ MicroBenchmarks/XRay/CMakeLists.txt
@@ -3,11 +3,21 @@
file(COPY lit.local.cfg DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
list(APPEND CPPFLAGS -std=c++11 -Wl,--gc-sections -fxray-instrument)
- set(Source retref-bench.cc)
list(APPEND LDFLAGS -fxray-instrument)
- set(RUN_OPTIONS --benchmark_repetitions=10 --benchmark_report_aggregates_only=true)
-
- set(PROG retref-bench)
- llvm_multisource()
+ llvm_test_run(--benchmark_filter=dummy_skip_ignore)
+ llvm_test_executable(retref-bench retref-bench.cc)
target_link_libraries(retref-bench benchmark)
+
+ file(COPY retref-bench_BM_ReturnNeverInstrumented.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
+ file(COPY retref-bench_BM_ReturnInstrumentedUnPatched.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
+ file(COPY retref-bench_BM_ReturnInstrumentedPatchedThenUnpatched.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
+ file(COPY retref-bench_BM_ReturnInstrumentedPatched.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
+ file(COPY retref-bench_BM_RDTSCP_Cost.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
+ file(COPY retref-bench_BM_ReturnInstrumentedPatchedWithLogHandler.test
+ DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35672.109531.patch
Type: text/x-patch
Size: 3730 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170803/e29f01a2/attachment.bin>
More information about the llvm-commits
mailing list