From 66995c1c5265b138915c6c1cd9ab91866a0ba4c1 Mon Sep 17 00:00:00 2001
From: Tomas Oberhuber <tomas.oberhuber@fjfi.cvut.cz>
Date: Fri, 14 Dec 2018 12:29:42 +0100
Subject: [PATCH] Added explicit conversions to String in Benchmark.

---
 src/Benchmarks/Benchmarks.h | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/Benchmarks/Benchmarks.h b/src/Benchmarks/Benchmarks.h
index de3727b212..ceb6b9c7eb 100644
--- a/src/Benchmarks/Benchmarks.h
+++ b/src/Benchmarks/Benchmarks.h
@@ -504,9 +504,9 @@ Benchmark::MetadataMap getHardwareMetadata()
        { "system release", Devices::SystemInfo::getSystemRelease() },
        { "start time", Devices::SystemInfo::getCurrentTime() },
 #ifdef HAVE_MPI
-       { "number of MPI processes", (Communicators::MpiCommunicator::IsInitialized())
+       { "number of MPI processes", String( (Communicators::MpiCommunicator::IsInitialized())
                                        ? Communicators::MpiCommunicator::GetSize( Communicators::MpiCommunicator::AllGroup )
-                                       : 1 },
+                                       : 1 ) },
 #endif
        { "OpenMP enabled", String( Devices::Host::isOMPEnabled() ) },
        { "OpenMP threads", String( Devices::Host::getMaxThreadsCount() ) },
@@ -517,12 +517,12 @@ Benchmark::MetadataMap getHardwareMetadata()
        { "CPU cache sizes (L1d, L1i, L2, L3) (kiB)", cacheInfo },
 #ifdef HAVE_CUDA
        { "GPU name", Devices::CudaDeviceInfo::getDeviceName( activeGPU ) },
-       { "GPU architecture", deviceArch },
-       { "GPU CUDA cores", Devices::CudaDeviceInfo::getCudaCores( activeGPU ) },
-       { "GPU clock rate (MHz)", (double) Devices::CudaDeviceInfo::getClockRate( activeGPU ) / 1e3 },
-       { "GPU global memory (GB)", (double) Devices::CudaDeviceInfo::getGlobalMemory( activeGPU ) / 1e9 },
-       { "GPU memory clock rate (MHz)", (double) Devices::CudaDeviceInfo::getMemoryClockRate( activeGPU ) / 1e3 },
-       { "GPU memory ECC enabled", Devices::CudaDeviceInfo::getECCEnabled( activeGPU ) },
+       { "GPU architecture", String( deviceArch ) },
+       { "GPU CUDA cores", String( Devices::CudaDeviceInfo::getCudaCores( activeGPU ) ) },
+       { "GPU clock rate (MHz)", String( (double) Devices::CudaDeviceInfo::getClockRate( activeGPU ) / 1e3 ) },
+       { "GPU global memory (GB)", String( (double) Devices::CudaDeviceInfo::getGlobalMemory( activeGPU ) / 1e9 ) },
+       { "GPU memory clock rate (MHz)", String( (double) Devices::CudaDeviceInfo::getMemoryClockRate( activeGPU ) / 1e3 ) },
+       { "GPU memory ECC enabled", String( Devices::CudaDeviceInfo::getECCEnabled( activeGPU ) ) },
 #endif
    };
 
-- 
GitLab