message: Do not copy scalar values from device and sync if logging is disabled
diff: @@ -142,6 +142,8 @@ T log_trace_scalar_value(const T* value)
  template <typename T>
  T log_trace_scalar_value(rocsparse_handle handle, const T* value)
  +{
  + if(handle->layer_mode & rocsparse_layer_mode_log_trace)
  {
  T host;
  if(value && handle->pointer_mode == rocsparse_pointer_mode_device)
  @@ -153,6 +155,8 @@ T log_trace_scalar_value(rocsparse_handle handle, const T* value)
  }
  return log_trace_scalar_value(value);
  }
  + return T{};
  +}
  #define LOG_TRACE_SCALAR_VALUE(handle, value) log_trace_scalar_value(handle, value)
  @@ -165,6 +169,8 @@ T log_bench_scalar_value(const T* value)
  template <typename T>
  T log_bench_scalar_value(rocsparse_handle handle, const T* value)
  +{
  + if(handle->layer_mode & rocsparse_layer_mode_log_bench)
  {
  T host;
  if(value && handle->pointer_mode == rocsparse_pointer_mode_device)
  @@ -176,6 +182,8 @@ T log_bench_scalar_value(rocsparse_handle handle, const T* value)
  }
  return log_bench_scalar_value(value);
  }
  + return T{};
  +}
  #define LOG_BENCH_SCALAR_VALUE(handle, name) log_bench_scalar_value(handle, name)
  