Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

int Impala::Core::Matrix::DistributedAccess::GetData ( double *  buffer,
int  bufferlength,
Util::PropertySet cmd,
const std::vector< int > &  parts 
) [inline, private]

Definition at line 630 of file DistributedAccess.h.

References Impala::Util::PropertySet::Add(), Impala::Core::Vector::VectorTem< ElemT >::Elem(), GetDataFromPart(), Impala::Util::PropertySet::GetDescription(), Impala::Util::PropertySet::GetInt(), GetOwnerOfPart(), Impala::Util::PropertySet::GetString(), ILOG_ERROR, and Impala::Core::Vector::VectorTem< ElemT >::Size().

Referenced by GetColumn(), GetDiagonal(), and GetRow().

00632     {
00633         int received=0;
00634         for (int i=0 ; i<parts.size(); i++)
00635         {
00636             if (Link::Mpi::MpiUsed())
00637             {
00638                 int owner = GetOwnerOfPart(parts[i]);
00639                 cmd.Add("part", parts[i]);
00640                 Link::Mpi::SendString(cmd.GetDescription(), owner);
00641                 double* b = buffer + received;
00642                 int l = Link::Mpi::ReceiveData(b, bufferlength-received, owner);
00643                 received += l;
00644             }
00645             else
00646             {
00647                 Vector64 v = GetDataFromPart(cmd.GetString("cmd"), parts[i],
00648                                              cmd.GetInt("arg"));
00649                 double* b = buffer + received;
00650                 if (v.Size() > bufferlength-received)
00651                     ILOG_ERROR("[GetData] buffer too small");
00652                 for (int j=0 ; j<v.Size() ; j++)
00653                     b[j] = v.Elem(j);
00654                 received += v.Size();
00655             }
00656         }
00657         return received;
00658     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:20:19 2011 for ImpalaSrc by  doxygen 1.5.1