YAC 3.12.0
Yet Another Coupler
Loading...
Searching...
No Matches
interp_operator.c
Go to the documentation of this file.
1// Copyright (c) 2025 The YAC Authors
2//
3// SPDX-License-Identifier: BSD-3-Clause
4
6
8 return interp->vtable->is_source(interp);
9}
10
12 return interp->vtable->is_target(interp);
13}
14
16 struct yac_interp_operator *interp,
17 double ***src_fields, double ***src_frac_masks,
18 double **tgt_field, double frac_mask_fallback_value,
19 double scale_factor, double scale_summand) {
20 interp->vtable->execute(
21 interp, src_fields, src_frac_masks, tgt_field,
22 frac_mask_fallback_value, scale_factor, scale_summand);
23}
24
26 struct yac_interp_operator *interp,
27 double ***src_fields, double ***src_frac_masks,
28 int is_target, double frac_mask_fallback_value,
29 double scale_factor, double scale_summand) {
30 interp->vtable->execute_put(
31 interp, src_fields, src_frac_masks, is_target,
32 frac_mask_fallback_value, scale_factor, scale_summand);
33}
34
36 struct yac_interp_operator *interp,
37 double **tgt_field, double frac_mask_fallback_value,
38 double scale_factor, double scale_summand) {
39 interp->vtable->execute_get(
40 interp, tgt_field, frac_mask_fallback_value,
41 scale_factor, scale_summand);
42}
43
45 struct yac_interp_operator *interp,
46 double **tgt_field, double frac_mask_fallback_value,
47 double scale_factor, double scale_summand) {
48 interp->vtable->execute_get_async(
49 interp, tgt_field, frac_mask_fallback_value,
50 scale_factor, scale_summand);
51}
52
54 struct yac_interp_operator *interp) {
55 return interp->vtable->execute_put_test(interp);
56}
57
59 struct yac_interp_operator *interp) {
60 return interp->vtable->execute_get_test(interp);
61}
62
64 interp->vtable->execute_wait(interp);
65}
66
68 struct yac_interp_operator *interp) {
69 return interp->vtable->copy(interp);
70}
71
73 interp->vtable->delete(interp);
74}
void yac_interp_operator_execute_wait(struct yac_interp_operator *interp)
Wait for all pending put/get operations to finish.
int yac_interp_operator_is_target(struct yac_interp_operator *interp)
Checks if the current process holds target data for the interpolation operator.
struct yac_interp_operator * yac_interp_operator_copy(struct yac_interp_operator *interp)
Create a deep copy of the interpolation operator.
enum YAC_INTERP_TEST_STATUS yac_interp_operator_execute_put_test(struct yac_interp_operator *interp)
Test whether the put phase has completed.
int yac_interp_operator_is_source(struct yac_interp_operator *interp)
Checks if the current process holds source data for the interpolation operator.
enum YAC_INTERP_TEST_STATUS yac_interp_operator_execute_get_test(struct yac_interp_operator *interp)
Test whether the get phase has completed.
void yac_interp_operator_execute_get(struct yac_interp_operator *interp, double **tgt_field, double frac_mask_fallback_value, double scale_factor, double scale_summand)
void yac_interp_operator_execute_put(struct yac_interp_operator *interp, double ***src_fields, double ***src_frac_masks, int is_target, double frac_mask_fallback_value, double scale_factor, double scale_summand)
void yac_interp_operator_execute_get_async(struct yac_interp_operator *interp, double **tgt_field, double frac_mask_fallback_value, double scale_factor, double scale_summand)
void yac_interp_operator_execute(struct yac_interp_operator *interp, double ***src_fields, double ***src_frac_masks, double **tgt_field, double frac_mask_fallback_value, double scale_factor, double scale_summand)
void yac_interp_operator_delete(struct yac_interp_operator *interp)
Delete the interpolation operator and free resources.
YAC_INTERP_TEST_STATUS
Abstract interpolation operator type.