OpenMPI 0.1.1

- Main Page
- Related Pages
- Modules
- Data Structures
- Files

- File List
- Globals

btl_self_frag.h
Go to the documentation of this file.
1 /*
2 * Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
3 * University Research and Technology
4 * Corporation. All rights reserved.
5 * Copyright (c) 2004-2008 The University of Tennessee and The University
6 * of Tennessee Research Foundation. All rights
7 * reserved.
8 * Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
9 * University of Stuttgart. All rights reserved.
10 * Copyright (c) 2004-2005 The Regents of the University of California.
11 * All rights reserved.
12 * $COPYRIGHT$
13 *
14 * Additional copyrights may follow
15 *
16 * $HEADER$
17 */
18 /**
19 * @file
20 */
21 #ifndef MCA_BTL_SELF_SEND_FRAG_H
22 #define MCA_BTL_SELF_SEND_FRAG_H
23
24 #include <sys/types.h>
25 #include "ompi/class/ompi_free_list.h"
26 #include "btl_self.h"
27
28
29 /**
30 * shared memory send fragment derived type.
31 */
32 struct mca_btl_self_frag_t {
33 mca_btl_base_descriptor_t base;
34 mca_btl_base_segment_t segment;
35 struct mca_btl_base_endpoint_t *endpoint;
36 size_t size;
37 };
38 typedef struct mca_btl_self_frag_t mca_btl_self_frag_t;
39 typedef struct mca_btl_self_frag_t mca_btl_self_frag_eager_t;
40 typedef struct mca_btl_self_frag_t mca_btl_self_frag_send_t;
41 typedef struct mca_btl_self_frag_t mca_btl_self_frag_rdma_t;
42
43 OBJ_CLASS_DECLARATION(mca_btl_self_frag_eager_t);
44 OBJ_CLASS_DECLARATION(mca_btl_self_frag_send_t);
45 OBJ_CLASS_DECLARATION(mca_btl_self_frag_rdma_t);
46
47 #define MCA_BTL_SELF_FRAG_ALLOC_EAGER(frag, rc) \
48 { \
49 ompi_free_list_item_t* item; \
50 OMPI_FREE_LIST_GET(&mca_btl_self_component.self_frags_eager, item, rc); \
51 frag = (mca_btl_self_frag_t*)item; \
52 }
53
54 #define MCA_BTL_SELF_FRAG_RETURN_EAGER(frag) \
55 { \
56 OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_eager, \
57 (ompi_free_list_item_t*)(frag)); \
58 frag->segment.seg_addr.pval = frag+1; \
59 }
60
61 #define MCA_BTL_SELF_FRAG_ALLOC_SEND(frag, rc) \
62 { \
63 ompi_free_list_item_t* item; \
64 OMPI_FREE_LIST_GET(&mca_btl_self_component.self_frags_send, item, rc); \
65 frag = (mca_btl_self_frag_t*)item; \
66 }
67
68 #define MCA_BTL_SELF_FRAG_RETURN_SEND(frag) \
69 { \
70 OMPI_FREE_LIST_RETURN( &mca_btl_self_component.self_frags_send, \
71 (ompi_free_list_item_t*)(frag)); \
72 frag->segment.seg_addr.pval = frag+1; \
73 }
74
75 #define MCA_BTL_SELF_FRAG_ALLOC_RDMA(frag, rc) \
76 { \
77 ompi_free_list_item_t* item; \
78 OMPI_FREE_LIST_GET(&mca_btl_self_component.self_frags_rdma, item, rc); \
79 frag = (mca_btl_self_frag_t*)item; \
80 }
81
82 #define MCA_BTL_SELF_FRAG_RETURN_RDMA(frag) \
83 { \
84 OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_rdma, \
85 (ompi_free_list_item_t*)(frag)); \
86 frag->segment.seg_addr.pval = frag+1; \
87 }
88
89 #endif
90
mca_btl_base_descriptor_t
A descriptor that holds the parameters to a send/put/get operation along w/ a callback routine that i...
Definition: btl.h:275
mca_btl_self_frag_t
shared memory send fragment derived type.
Definition: btl_self_frag.h:32
btl_self.h
mca_btl_base_endpoint_t
State of ELAN endpoint connection.
Definition: btl_elan_endpoint.h:33
mca_btl_base_segment_t
Describes a region/segment of memory that is addressable by an BTL.
Definition: btl.h:236
OBJ_CLASS_DECLARATION
#define OBJ_CLASS_DECLARATION(NAME)
Declaration for class descriptor.
Definition: opal_object.h:236