74 typedef typename Message::size_type size_type;
78 from.requests.clear();
80 size_type n_receive = from.starts().size() - 1;
81 size_type i_start = 0;
82 for (size_type i = 0; i < n_receive; i++) {
83 size_type i_size = from.starts() [i+1] - from.starts() [i];
84 mpi::request i_req = comm.irecv(
87 from.values().begin().operator->() + i_start,
90 from.requests.push_back (std::make_pair(i, i_req));
103 size_type n_send = to.starts().size() - 1;
104 size_type i_start = 0;
105 for (size_type i = 0; i < n_send; i++) {
106 size_type i_size = to.starts() [i+1] - to.starts() [i];
107 mpi::request i_req = comm.isend(
110 to.values().begin().operator->() + i_start,
113 to.requests.push_back (std::make_pair(i, i_req));
151 details::generic_set_op op)
155 if (y == x && ! to.local_nonmatching_computed) {
157 fatal_macro (
"y == x: adress matches in scatter: not yet -- sorry");
159 if (to.local_is_copy) {
161 std::copy(x + to.local_copy_start,
162 x + to.local_copy_start + to.local_copy_length,
163 y + from.local_copy_start);
165 }
else if (y != x || ! to.local_nonmatching_computed) {
168 to.local_slots.begin(),
169 to.local_slots.end(),
172 from.local_slots.begin(),
178 to.local_slots_nonmatching.begin(),
179 to.local_slots_nonmatching.end(),
182 from.local_slots_nonmatching.begin(),
void mpi_scatter_begin(InputIterator x, OutputIterator y, Message &from, Message &to, SetOp op, Tag tag, Comm comm)