MCPcopy Create free account
hub / github.com/Kitware/VTK / ExchangeCountsFast

Method ExchangeCountsFast

Filters/ParallelGeometry/vtkPDistributedDataFilter.cxx:1758–1769  ·  view source on GitHub ↗

----------------------- Fast versions ----------------------------//

Source from the content-addressed store, hash-verified

1756
1757// ----------------------- Fast versions ----------------------------//
1758vtkIdTypeArray* vtkPDistributedDataFilter::ExchangeCountsFast(
1759 vtkIdType myCount, int vtkNotUsed(tag))
1760{
1761 int nprocs = this->NumProcesses;
1762
1763 vtkIdType* counts = new vtkIdType[nprocs];
1764 this->Controller->AllGather(&myCount, counts, 1);
1765
1766 vtkIdTypeArray* countArray = vtkIdTypeArray::New();
1767 countArray->SetArray(counts, nprocs, 0, vtkIdTypeArray::VTK_DATA_ARRAY_DELETE);
1768 return countArray;
1769}
1770
1771//------------------------------------------------------------------------------
1772vtkFloatArray** vtkPDistributedDataFilter::ExchangeFloatArraysFast(

Callers 1

ExchangeCountsMethod · 0.95

Calls 3

NewFunction · 0.50
AllGatherMethod · 0.45
SetArrayMethod · 0.45

Tested by

no test coverage detected