/[escript]/trunk/finley/src/ElementDistribution_allocTable.c
ViewVC logotype

Contents of /trunk/finley/src/ElementDistribution_allocTable.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1028 - (show annotations)
Wed Mar 14 00:15:24 2007 UTC (12 years, 4 months ago) by gross
File MIME type: text/plain
File size: 710 byte(s)
modifications to be compliant with _WIN32. The substitutes for asinh, acosh, atanh are still missing (erf will through an exception)
1
2 #ifdef PASO_MPI
3 #include "Distribution.h"
4
5 /* note that numElementsThis is the number of elements assigned to this process */
6 void Finley_ElementDistribution_allocTable( Finley_ElementDistribution *in, dim_t numElements, dim_t numElementsThis ){
7 index_t i;
8
9 in->numLocal = numElements;
10 in->numBoundary = 0;
11 in->numInternal = 0;
12 in->vtxdist = MEMALLOC(in->MPIInfo->size+1,dim_t);
13 in->vtxdist[0] = 0;
14 if( in->MPIInfo->size>1 )
15 MPI_Allgather( &numElementsThis, 1, MPI_INT, in->vtxdist+1, 1, MPI_INT, in->MPIInfo->comm );
16 else
17 in->vtxdist[1] = numElements;
18 for( i=0; i<in->MPIInfo->size; i++ )
19 in->vtxdist[i+1] += in->vtxdist[i];
20 }
21 #else
22 void Finley_ElementDistribution_allocTable(void){
23 }
24 #endif

  ViewVC Help
Powered by ViewVC 1.1.26