Yet Another eXchange Tool 0.11.2
Loading...
Searching...
No Matches
xt_xmap_internal.h
Go to the documentation of this file.
1
13/*
14 * Keywords:
15 * Maintainer: Jörg Behrens <behrens@dkrz.de>
16 * Moritz Hanke <hanke@dkrz.de>
17 * Thomas Jahns <jahns@dkrz.de>
18 * URL: https://dkrz-sw.gitlab-pages.dkrz.de/yaxt/
19 *
20 * Redistribution and use in source and binary forms, with or without
21 * modification, are permitted provided that the following conditions are
22 * met:
23 *
24 * Redistributions of source code must retain the above copyright notice,
25 * this list of conditions and the following disclaimer.
26 *
27 * Redistributions in binary form must reproduce the above copyright
28 * notice, this list of conditions and the following disclaimer in the
29 * documentation and/or other materials provided with the distribution.
30 *
31 * Neither the name of the DKRZ GmbH nor the names of its contributors
32 * may be used to endorse or promote products derived from this software
33 * without specific prior written permission.
34 *
35 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
36 * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
37 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
38 * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
39 * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
40 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
41 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
42 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
43 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
44 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
45 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
46 */
47#ifndef XT_XMAP_INTERNAL_H
48#define XT_XMAP_INTERNAL_H
49
50#ifdef HAVE_CONFIG_H
51#include <config.h>
52#endif
53
54#include <mpi.h>
55
56#include "xt/xt_xmap.h"
57
59 int (*next)(Xt_xmap_iter iter);
60 int (*get_rank)(Xt_xmap_iter iter);
61 int const * (*get_transfer_pos)(Xt_xmap_iter iter);
63 const struct Xt_pos_ext *(*get_transfer_pos_ext)(Xt_xmap_iter iter);
65 void (*delete)(Xt_xmap_iter iter);
66};
67
69 const struct Xt_xmap_iter_vtable * vtable;
70};
71
72
74
79 void (*get_source_ranks)(Xt_xmap, int*);
83 void (*delete)(Xt_xmap);
86 Xt_xmap (*reorder)(Xt_xmap xmap, enum xt_reorder_type type, Xt_config config);
88 const int * src_positions, const int * dst_positions);
89 Xt_xmap (*spread)(Xt_xmap xmap, int num_repetitions,
90 const int src_displacements[num_repetitions],
91 const int dst_displacements[num_repetitions]);
92};
93
94struct Xt_xmap_ {
95 const struct Xt_xmap_vtable * vtable;
96};
97
98#endif
99
100/*
101 * Local Variables:
102 * c-basic-offset: 2
103 * coding: utf-8
104 * indent-tabs-mode: nil
105 * show-trailing-whitespace: t
106 * require-trailing-newline: t
107 * End:
108 */
int MPI_Comm
Definition core.h:64
const struct Xt_xmap_vtable * vtable
const struct Xt_xmap_iter_vtable * vtable
int(* get_num_transfer_pos)(Xt_xmap_iter iter)
int(* next)(Xt_xmap_iter iter)
int(* get_rank)(Xt_xmap_iter iter)
int(* get_num_transfer_pos_ext)(Xt_xmap_iter iter)
Xt_xmap(* update_pos)(Xt_xmap xmap, const int *src_positions, const int *dst_positions)
int(* get_num_destinations)(Xt_xmap)
MPI_Comm(* get_communicator)(Xt_xmap)
int(* get_max_dst_pos)(Xt_xmap)
Xt_xmap_iter(* get_out_iterator)(Xt_xmap)
Xt_xmap_iter(* get_in_iterator)(Xt_xmap)
void(* get_source_ranks)(Xt_xmap, int *)
Xt_xmap(* spread)(Xt_xmap xmap, int num_repetitions, const int src_displacements[num_repetitions], const int dst_displacements[num_repetitions])
int(* get_max_src_pos)(Xt_xmap)
Xt_xmap(* reorder)(Xt_xmap xmap, enum xt_reorder_type type, Xt_config config)
Xt_xmap(* copy)(Xt_xmap)
int(* get_num_sources)(Xt_xmap)
void(* get_destination_ranks)(Xt_xmap, int *)
struct Xt_config_ * Xt_config
Definition xt_config.h:58
struct Xt_xmap_ * Xt_xmap
Definition xt_core.h:85
exchange map declarations
struct Xt_xmap_iter_ * Xt_xmap_iter
Definition xt_xmap.h:73
xt_reorder_type
Definition xt_xmap.h:240