Commit f1aad62b authored by Yaroslav's avatar Yaroslav

Working on SGather

parent d5e19cda
......@@ -140,6 +140,8 @@ private:
{
for (size_t i = 0 ; i < recv_buf.size() ; i++)
{
//std::cout << "I: " << i << ", Rec_buf.get(i).size(): " << recv_buf.get(i).size() << std::endl;
// calculate the number of received elements
size_t n_ele = recv_buf.get(i).size() / sizeof(typename T::value_type);
......@@ -220,6 +222,8 @@ static void * msg_alloc(size_t msg_i ,size_t total_msg, size_t total_p, size_t i
rinfo.recv_buf->get(ri).resize(msg_i);
std::cout << "Recv_but.get(ri).size(): " << rinfo.recv_buf->get(ri).size() << std::endl;
// Receive info
rinfo.prc.add(i);
rinfo.sz.add(msg_i);
......@@ -375,7 +379,7 @@ template<typename T, typename S> bool SGather(T & send, S & recv, openfpm::vecto
send_buf.add(mem.getPointer());
openfpm::vector<size_t> sz;
sz.add(send.size());
sz.add(send.size()*sizeof(typename T::value_type));
// receive information
base_info bi(NULL,prc,sz);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment