From 985d6db0647745586f5389ee00422122f92da3e4 Mon Sep 17 00:00:00 2001 From: Bernhard Manfred Gruber Date: Tue, 17 May 2022 11:22:52 +0200 Subject: [PATCH] fix warning on using TimeStampCounter uninitialized --- examples/matrix/main.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/examples/matrix/main.cpp b/examples/matrix/main.cpp index 2d50c87f5..e990392e9 100644 --- a/examples/matrix/main.cpp +++ b/examples/matrix/main.cpp @@ -252,8 +252,7 @@ template void unused(T &&x) { asm("" ::"m"(x)); } template Vc_ALWAYS_INLINE void benchmark(F &&f) { TimeStampCounter tsc; - auto cycles = tsc.cycles(); - cycles = 0x7fffffff; + decltype(tsc.cycles()) cycles = 0x7fffffff; for (int i = 0; i < 100; ++i) { tsc.start(); for (int j = 0; j < 10; ++j) {