[PATCH] D53030: [MicroBenchmark] Add initial LoopInterchange test/benchmark.

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 16 16:21:41 PDT 2018


MatzeB added inline comments.


================
Comment at: MicroBenchmarks/LoopInterchange/main.cpp:19
+
+static int test1(int M, int N) {
+
----------------
`M` and `N` are unused?


================
Comment at: MicroBenchmarks/LoopInterchange/main.cpp:58-59
+    int y = test1(M, N);
+    if (state.range(0) == 20)
+      printf("%d\n", y);
+  }
----------------
Is the `printf` here a good idea? You'll artificially make one iteration slower which could possibly make the benchmark library take longer to stabilize until the result is statistically significant.


Repository:
  rT test-suite

https://reviews.llvm.org/D53030





More information about the llvm-commits mailing list