/[escript]/trunk/paso/src/SharedComponents.h
ViewVC logotype

Annotation of /trunk/paso/src/SharedComponents.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2068 - (hide annotations)
Thu Nov 20 09:11:01 2008 UTC (10 years, 11 months ago) by phornby
File MIME type: text/plain
File size: 2427 byte(s)
Interim commit getting paso ready for becoming a shared library.


1 ksteube 1313
2     /*******************************************************
3 ksteube 1811 *
4     * Copyright (c) 2003-2008 by University of Queensland
5     * Earth Systems Science Computational Center (ESSCC)
6     * http://www.uq.edu.au/esscc
7     *
8     * Primary Business: Queensland, Australia
9     * Licensed under the Open Software License version 3.0
10     * http://www.opensource.org/licenses/osl-3.0.php
11     *
12     *******************************************************/
13 ksteube 1313
14 ksteube 1811
15 ksteube 1313 /**************************************************************/
16    
17     /* Paso: coupler */
18    
19     /**************************************************************/
20    
21     /* Author: gross@access.edu.au */
22    
23     /**************************************************************/
24    
25     #ifndef INC_PASO_SHAREDCOMPONENTS
26     #define INC_PASO_SHAREDCOMPONENTS
27    
28     #include "Paso_MPI.h"
29     #include "Common.h"
30    
31     /**************************************************************/
32    
33     typedef struct Paso_SharedComponents {
34    
35 gross 1562 dim_t local_length; /* local array length shared */
36    
37 ksteube 1313 dim_t numNeighbors; /* number of processor sharing values with this processor */
38    
39     index_t* offsetInShared; /* offsetInSharedInput[i] points to the first input value in array shared
40     for processor i. Has length numNeighbors+1 */
41    
42     Paso_MPI_rank* neighbor; /* list of the processor sharing values with this processor */
43    
44     index_t* shared; /* list of the (local) componets which is shared with other
45     processors. Has length numSharedComponents */
46    
47     dim_t numSharedComponents; /* = offsetInShared[numNeighbors] */
48    
49     Paso_MPIInfo *mpi_info;
50     dim_t reference_counter;
51    
52     } Paso_SharedComponents;
53    
54    
55 phornby 2068
56     PASO_DLL_API
57 gross 1562 Paso_SharedComponents* Paso_SharedComponents_alloc(dim_t local_length,
58     dim_t numNeighbors,
59 ksteube 1313 Paso_MPI_rank* neighbor,
60     index_t* shared,
61     index_t* offsetInShared,
62     index_t m, index_t b,
63     Paso_MPIInfo *mpi_info);
64    
65 phornby 2068
66     PASO_DLL_API
67 ksteube 1313 Paso_SharedComponents* Paso_SharedComponents_getReference(Paso_SharedComponents*);
68 phornby 2068
69     PASO_DLL_API
70 ksteube 1313 void Paso_SharedComponents_free(Paso_SharedComponents*);
71    
72     #endif

  ViewVC Help
Powered by ViewVC 1.1.26