xref: /libCEED/backends/sycl-shared/ceed-sycl-shared.hpp (revision d83cf49fece5d7d5441d5b92eb712b904329a4d2)
1 // Copyright (c) 2017-2024, Lawrence Livermore National Security, LLC and other CEED contributors.
2 // All Rights Reserved. See the top-level LICENSE and NOTICE files for details.
3 //
4 // SPDX-License-Identifier: BSD-2-Clause
5 //
6 // This file is part of CEED:  http://github.com/ceed
7 #pragma once
8 
9 #include <ceed/backend.h>
10 #include <ceed/ceed.h>
11 
12 #include <sycl/sycl.hpp>
13 
14 #include "../sycl/ceed-sycl-common.hpp"
15 #include "../sycl/ceed-sycl-compile.hpp"
16 
17 typedef struct {
18   CeedInt       interp_local_range[3];
19   CeedInt       grad_local_range[3];
20   CeedInt       weight_local_range[3];
21   SyclModule_t *sycl_module;
22   sycl::kernel *interp_kernel;
23   sycl::kernel *interp_transpose_kernel;
24   sycl::kernel *grad_kernel;
25   sycl::kernel *grad_transpose_kernel;
26   sycl::kernel *weight_kernel;
27   CeedScalar   *d_interp_1d;
28   CeedScalar   *d_grad_1d;
29   CeedScalar   *d_collo_grad_1d;  // eliminate
30   CeedScalar   *d_q_weight_1d;
31 } CeedBasis_Sycl_shared;
32 
33 CEED_INTERN int CeedBasisCreateTensorH1_Sycl_shared(CeedInt dim, CeedInt P_1d, CeedInt Q_1d, const CeedScalar *interp_1d, const CeedScalar *grad_1d,
34                                                     const CeedScalar *q_ref_1d, const CeedScalar *q_weight_1d, CeedBasis basis);
35