VTK: Parallel/DIY/vtkDIYExplicitAssigner.h Source File

| VTK 9.3.1

vtkDIYExplicitAssigner.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
22 #ifndef vtkDIYExplicitAssigner_h
23 #define vtkDIYExplicitAssigner_h
24
25 #include "vtkObject.h"
26 #include "vtkParallelDIYModule.h" // for export macros
27 // clang-format off
28 #include "vtk_diy2.h"
29 #include VTK_DIY2(diy/mpi.hpp)
30 #include VTK_DIY2(diy/assigner.hpp)
31 // clang-format on
32
33 #ifdef _WIN32
34 #pragma warning(disable : 4275) /* non dll-interface class `diy::StaticAssigner` used as base for \
35 dll-interface class */
36 #endif
37
38 VTK_ABI_NAMESPACE_BEGIN
39 class VTKPARALLELDIY_EXPORT vtkDIYExplicitAssigner : public diy::StaticAssigner
40 {
41 public:
42 vtkDIYExplicitAssigner(
43 diy::mpi::communicator comm, int local_blocks, bool force_power_of_two = false);
44
45 int rank(int gid) const override;
46 void local_gids(int rank, std::vector<int>& gids) const override;
47
48 private:
49 std::vector<int> IScanBlockCounts;
50 };
51
52 VTK_ABI_NAMESPACE_END
53 #endif
54 // VTK-HeaderTest-Exclude: vtkDIYExplicitAssigner.h
vtkDIYExplicitAssigner
assigner for use with DIY
Definition: vtkDIYExplicitAssigner.h:40
vtkDIYExplicitAssigner::rank
int rank(int gid) const override
vtkDIYExplicitAssigner::local_gids
void local_gids(int rank, std::vector< int > &gids) const override
vtkDIYExplicitAssigner::vtkDIYExplicitAssigner
vtkDIYExplicitAssigner(diy::mpi::communicator comm, int local_blocks, bool force_power_of_two=false)
vtkObject.h