16#ifndef dealii_base_mpi_compute_index_owner_internal_h
17#define dealii_base_mpi_compute_index_owner_internal_h
36 namespace ComputeIndexOwner
49 const bool index_range_contiguous,
50 const std::size_t
size);
53 fill(
const std::size_t start,
54 const std::size_t end,
69 std::vector<index_type>
data;
83 std::pair<types::global_dof_index, types::global_dof_index>>,
84 std::vector<unsigned int>>
91 const std::map<
unsigned int,
96 const std::pair<types::global_dof_index, types::global_dof_index>
104 virtual std::vector<unsigned int>
115 &send_buffer)
override;
123 const unsigned int other_rank,
126 std::vector<unsigned int> &request_buffer)
override;
129 const std::map<
unsigned int,
136 const std::pair<types::global_dof_index, types::global_dof_index>
209 std::pair<types::global_dof_index, types::global_dof_index>
267 const unsigned int guess = 0);
289 std::pair<types::global_dof_index, types::global_dof_index>>,
290 std::vector<unsigned int>>
352 std::vector<std::vector<
353 std::pair<
unsigned int,
354 std::vector<std::pair<unsigned int, unsigned int>>>>>
366 std::map<unsigned int, std::vector<types::global_dof_index>>
384 const unsigned int other_rank,
387 std::vector<unsigned int> &request_buffer)
override;
393 virtual std::vector<unsigned int>
404 &send_buffer)
override;
412 const std::vector<unsigned int> &recv_buffer)
override;
423 std::map<unsigned int, IndexSet>
442 unsigned int & owner_index,
443 const unsigned int rank_of_request);
471 const unsigned int rank_in_owned_indices,
472 const unsigned int guess)
481 rank_in_owned_indices);
const unsigned int my_rank
virtual std::vector< unsigned int > compute_targets() override
virtual void answer_request(const unsigned int other_rank, const std::vector< std::pair< types::global_dof_index, types::global_dof_index > > &buffer_recv, std::vector< unsigned int > &request_buffer) override
virtual void read_answer(const unsigned int other_rank, const std::vector< unsigned int > &recv_buffer) override
virtual void create_request(const unsigned int other_rank, std::vector< std::pair< types::global_dof_index, types::global_dof_index > > &send_buffer) override
std::vector< std::vector< std::pair< unsigned int, std::vector< std::pair< unsigned int, unsigned int > > > > > requesters
std::vector< unsigned int > & owning_ranks
void append_index_origin(const types::global_dof_index index, unsigned int &owner_index, const unsigned int rank_of_request)
const IndexSet & indices_to_look_up
const unsigned int n_procs
const IndexSet & owned_indices
std::map< unsigned int, IndexSet > get_requesters()
std::map< unsigned int, std::vector< unsigned int > > recv_indices
std::map< unsigned int, std::vector< types::global_dof_index > > indices_to_look_up_by_dict_rank
const bool track_index_requests
const std::map< unsigned int, std::vector< std::pair< types::global_dof_index, types::global_dof_index > > > & buffers
std::vector< unsigned int > & actually_owning_rank_list
virtual std::vector< unsigned int > compute_targets() override
virtual void answer_request(const unsigned int other_rank, const std::vector< std::pair< types::global_dof_index, types::global_dof_index > > &buffer_recv, std::vector< unsigned int > &request_buffer) override
virtual void create_request(const unsigned int other_rank, std::vector< std::pair< types::global_dof_index, types::global_dof_index > > &send_buffer) override
const std::pair< types::global_dof_index, types::global_dof_index > & local_range
FlexibleIndexStorage & actually_owning_ranks
index_type & operator[](const std::size_t index)
bool entry_has_been_set(const std::size_t index) const
void reinit(const bool use_vector, const bool index_range_contiguous, const std::size_t size)
static const index_type invalid_index_value
void fill(const std::size_t start, const std::size_t end, const index_type &value)
std::map< std::size_t, index_type > data_map
std::vector< index_type > data
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
#define Assert(cond, exc)
#define AssertIndexRange(index, range)
static ::ExceptionBase & ExcInternalError()
static const unsigned int invalid_unsigned_int
::VectorizedArray< Number, width > min(const ::VectorizedArray< Number, width > &, const ::VectorizedArray< Number, width > &)
unsigned int global_dof_index
std::vector< unsigned int > actually_owning_rank_list
void reinit(const IndexSet &owned_indices, const MPI_Comm &comm)
FlexibleIndexStorage actually_owning_ranks
unsigned int dof_to_dict_rank(const types::global_dof_index i)
types::global_dof_index get_index_offset(const unsigned int rank)
types::global_dof_index locally_owned_size
types::global_dof_index dofs_per_process
unsigned int n_dict_procs_in_owned_indices
static constexpr unsigned int sparsity_factor
unsigned int stride_small_size
static constexpr unsigned int range_minimum_grain_size
std::pair< types::global_dof_index, types::global_dof_index > local_range
void partition(const IndexSet &owned_indices, const MPI_Comm &comm)
unsigned int get_owning_rank_index(const unsigned int rank_in_owned_indices, const unsigned int guess=0)
types::global_dof_index size