Do not forget to commit the data-type once it is created from the
packed description. This commit was SVN r9125.
Этот коммит содержится в:
родитель
574c384ad4
Коммит
0c1c650c91
@ -385,8 +385,8 @@ int ompi_ddt_get_pack_description( ompi_datatype_t* datatype,
|
|||||||
return OMPI_SUCCESS;
|
return OMPI_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
ompi_datatype_t*
|
static ompi_datatype_t*
|
||||||
ompi_ddt_create_from_packed_description( void** packed_buffer,
|
__ompi_ddt_create_from_packed_description( void** packed_buffer,
|
||||||
struct ompi_proc_t* remote_processor )
|
struct ompi_proc_t* remote_processor )
|
||||||
{
|
{
|
||||||
int* position = (int*)*packed_buffer;
|
int* position = (int*)*packed_buffer;
|
||||||
@ -422,7 +422,7 @@ ompi_ddt_create_from_packed_description( void** packed_buffer,
|
|||||||
array_of_datatype[i] = (ompi_datatype_t*)ompi_ddt_basicDatatypes[position[i]];
|
array_of_datatype[i] = (ompi_datatype_t*)ompi_ddt_basicDatatypes[position[i]];
|
||||||
} else {
|
} else {
|
||||||
array_of_datatype[i] =
|
array_of_datatype[i] =
|
||||||
ompi_ddt_create_from_packed_description( (void**)&next_buffer,
|
__ompi_ddt_create_from_packed_description( (void**)&next_buffer,
|
||||||
remote_processor );
|
remote_processor );
|
||||||
if( NULL == array_of_datatype[i] )
|
if( NULL == array_of_datatype[i] )
|
||||||
goto cleanup_and_exit;
|
goto cleanup_and_exit;
|
||||||
@ -535,3 +535,19 @@ __ompi_ddt_create_from_args( int32_t* i, MPI_Aint* a,
|
|||||||
|
|
||||||
return datatype;
|
return datatype;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ompi_datatype_t*
|
||||||
|
ompi_ddt_create_from_packed_description( void** packed_buffer,
|
||||||
|
struct ompi_proc_t* remote_processor )
|
||||||
|
{
|
||||||
|
ompi_datatype_t* datatype;
|
||||||
|
|
||||||
|
datatype = __ompi_ddt_create_from_packed_description( packed_buffer,
|
||||||
|
remote_processor );
|
||||||
|
if( NULL == datatype ) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
ompi_ddt_commit( &datatype );
|
||||||
|
return datatype;
|
||||||
|
}
|
||||||
|
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user