14int main(
int narg,
char **arg)
20 int me = comm->getRank();
21 int np = comm->getSize();
24 int *ids =
new int[np/2+1];
25 for (
int i = 0; i < np/2+1; i++) ids[i] = i;
28 for (
int i = 0; i < niter; i++) {
30 = comm->createSubcommunicator(list);
31 printf(
"iteration %d -- weak: %d strong: %d total: %d\n",
Reference-counted pointer class and non-member templated function implementations.
static Teuchos::RCP< const Comm< OrdinalType > > getComm()
Return the default global communicator.
Initialize, finalize, and query the global MPI session.
Smart reference counting pointer class for automatic garbage collection.
int weak_count() const
Return the number of active RCP<> objects that have a "weak" reference to the underlying reference-co...
int total_count() const
Total count (strong_count() + weak_count()).
int strong_count() const
Return the number of active RCP<> objects that have a "strong" reference to the underlying reference-...