Lines Matching +full:boost +full:- +full:root
3 // Use, modification and distribution is subject to the Boost Software
5 // http://www.boost.org/LICENSE_1_0.txt)
9 #include <boost/mpi/collectives/scatter.hpp>
10 #include <boost/mpi/collectives/scatterv.hpp>
11 #include <boost/mpi/communicator.hpp>
12 #include <boost/mpi/environment.hpp>
14 #include <boost/serialization/string.hpp>
15 #include <boost/serialization/list.hpp>
16 #include <boost/iterator/counting_iterator.hpp>
17 #include <boost/lexical_cast.hpp>
20 #include <boost/test/included/unit_test.hpp>
22 using namespace boost::mpi;
27 const char* kind, int root = -1) in scatter_test() argument
31 if (root == -1) { in scatter_test()
32 for (root = 0; root < comm.size(); ++root) in scatter_test()
33 scatter_test(comm, generator, kind, root); in scatter_test()
35 using boost::mpi::scatter; in scatter_test()
39 if (comm.rank() == root) { in scatter_test()
45 std::cout << "Scattering " << kind << " from root " in scatter_test()
46 << root << "..." << std::endl; in scatter_test()
48 scatter(comm, values, value, root); in scatter_test()
50 scatter(comm, value, root); in scatter_test()
86 std::string result = boost::lexical_cast<std::string>(p); in operator ()()
101 std::string value = boost::lexical_cast<std::string>(i); in operator ()()
119 const char* kind, int root = -1) in scatterv_test() argument
123 if (root == -1) { in scatterv_test()
124 for (root = 0; root < comm.size(); ++root) in scatterv_test()
125 scatterv_test(comm, generator, kind, root); in scatterv_test()
127 using boost::mpi::scatterv; in scatterv_test()
132 if (comm.rank() == root) { in scatterv_test()
143 std::cout << "Scatteringv " << kind << " from root " in scatterv_test()
144 << root << "..." << std::endl; in scatterv_test()
146 scatterv(comm, values, sizes, &(myvalues[0]), root); in scatterv_test()
148 scatterv(comm, &(myvalues[0]), mysize, root); in scatterv_test()
161 const char* kind, int root = -1) in scatterd_test() argument
165 if (root == -1) { in scatterd_test()
166 for (root = 0; root < comm.size(); ++root) in scatterd_test()
167 scatterv_test(comm, generator, kind, root); in scatterd_test()
169 using boost::mpi::scatterv; in scatterd_test()
174 if (comm.rank() == root) { in scatterd_test()
180 // root will insert pseudo random pading between each payload. in scatterd_test()
198 std::cout << "Scatteringv " << kind << " from root " in scatterd_test()
199 << root << "..." << std::endl; in scatterd_test()
201 scatterv(comm, values, sizes, displs, &(myvalues[0]), mysize, root); in scatterd_test()
203 scatterv(comm, &(myvalues[0]), mysize, root); in scatterd_test()