xref: /libCEED/backends/blocked/ceed-blocked.h (revision b13efd58b277efef1db70d6f06eaaf4d415a7642)
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.h>
10 #include <ceed/backend.h>
11 #include <stdbool.h>
12 #include <stdint.h>
13 
14 typedef struct {
15   CeedScalar *colo_grad_1d;
16 } CeedBasis_Blocked;
17 
18 typedef struct {
19   bool                 is_identity_qf, is_identity_rstr_op;
20   bool                *skip_rstr_in, *skip_rstr_out, *apply_add_basis_out;
21   CeedInt             *e_data_out_indices;
22   uint64_t            *input_states; /* State counter of inputs */
23   CeedVector          *e_vecs_full;  /* Full E-vectors, inputs followed by outputs */
24   CeedVector          *e_vecs_in;    /* Element block input E-vectors  */
25   CeedVector          *e_vecs_out;   /* Element block output E-vectors */
26   CeedVector          *q_vecs_in;    /* Element block input Q-vectors  */
27   CeedVector          *q_vecs_out;   /* Element block output Q-vectors */
28   CeedElemRestriction *block_rstr;   /* Blocked versions of restrictions */
29   CeedInt              num_inputs, num_outputs;
30   CeedInt              qf_size_in, qf_size_out;
31   CeedVector           qf_l_vec;
32   CeedElemRestriction  qf_block_rstr;
33 } CeedOperator_Blocked;
34 
35 CEED_INTERN int CeedOperatorCreate_Blocked(CeedOperator op);
36