From 112a04abfe01131401320829cf208e113026fac4 Mon Sep 17 00:00:00 2001 From: nbeams <246972+nbeams@users.noreply.github.com> Date: Fri, 26 Aug 2022 13:20:26 -0600 Subject: [PATCH] Resolve conflicts when updating from main --- backends/cuda-ref/ceed-cuda-vector.c | 4 ++-- include/ceed/types.h | 9 ++++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/backends/cuda-ref/ceed-cuda-vector.c b/backends/cuda-ref/ceed-cuda-vector.c index 2ec324c2ff..14b6da89b5 100644 --- a/backends/cuda-ref/ceed-cuda-vector.c +++ b/backends/cuda-ref/ceed-cuda-vector.c @@ -113,8 +113,8 @@ static inline int CeedVectorSyncD2H_Cuda(const CeedVector vec) { // Sync arrays //------------------------------------------------------------------------------ static int CeedVectorSyncArrayGeneric_Cuda(const CeedVector vec, - CeedMemType mem_type, - CeedScalarType prec) { + CeedMemType mem_type, + CeedScalarType prec) { int ierr; // Check whether device/host sync is needed bool need_sync = false; diff --git a/include/ceed/types.h b/include/ceed/types.h index f9e74e7afa..161f68c6d3 100644 --- a/include/ceed/types.h +++ b/include/ceed/types.h @@ -112,8 +112,15 @@ typedef enum { /// Single precision CEED_SCALAR_FP32, /// Double precision - CEED_SCALAR_FP64 + CEED_SCALAR_FP64, + /// Total number of allowed scalar precision types + CEED_NUM_PRECISIONS, } CeedScalarType; +/// Struct for holding data in multiple precisions for mixed-precision-enabled +/// backends +typedef struct { + void *values[CEED_NUM_PRECISIONS]; // Size equals CEED_NUM_PRECISIONS +} CeedScalarArray; /// Base scalar type for the library to use: change which header is /// included to change the precision. #include "ceed-f64.h"