This source file includes following definitions.
- opal_datatype_resize
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 #include "opal_config.h"
17 #include "opal/constants.h"
18 #include "opal/datatype/opal_datatype.h"
19 #include "opal/datatype/opal_datatype_internal.h"
20
21 int32_t opal_datatype_resize( opal_datatype_t* type, ptrdiff_t lb, ptrdiff_t extent )
22 {
23 type->lb = lb;
24 type->ub = lb + extent;
25
26 type->flags &= ~OPAL_DATATYPE_FLAG_NO_GAPS;
27 if( (extent == (ptrdiff_t)type->size) &&
28 (type->flags & OPAL_DATATYPE_FLAG_CONTIGUOUS) ) {
29 type->flags |= OPAL_DATATYPE_FLAG_NO_GAPS;
30 }
31 return OPAL_SUCCESS;
32 }