Cleanups. Re-order the match size function and remove the now useless internal version.
This commit was SVN r10198.
Этот коммит содержится в:
родитель
18f095db16
Коммит
b682ecdff4
@ -21,12 +21,18 @@
|
||||
#include "ompi/datatype/datatype.h"
|
||||
#include "ompi/datatype/datatype_internal.h"
|
||||
|
||||
static inline
|
||||
const ompi_datatype_t* ompi_ddt_match_size_internal( int size, uint16_t datakind, uint16_t datalang )
|
||||
const ompi_datatype_t*
|
||||
ompi_ddt_match_size( int size, uint16_t datakind, uint16_t datalang )
|
||||
{
|
||||
uint32_t i;
|
||||
const ompi_datatype_t* datatype;
|
||||
|
||||
/* If we're not looking for a complex C++ type then set the default type to C */
|
||||
if( datalang == DT_FLAG_DATA_CPP ) {
|
||||
if( datakind != DT_FLAG_DATA_COMPLEX )
|
||||
datalang = DT_FLAG_DATA_C;
|
||||
}
|
||||
|
||||
for( i = 0; i < DT_MAX_PREDEFINED; i++ ) {
|
||||
datatype = ompi_ddt_basicDatatypes[i];
|
||||
if( (datatype->flags & DT_FLAG_DATA_LANGUAGE) != datalang )
|
||||
@ -39,13 +45,3 @@ const ompi_datatype_t* ompi_ddt_match_size_internal( int size, uint16_t datakind
|
||||
}
|
||||
return &ompi_mpi_datatype_null;
|
||||
}
|
||||
|
||||
const ompi_datatype_t* ompi_ddt_match_size( int size, uint16_t datakind, uint16_t datalang )
|
||||
{
|
||||
if( datalang == DT_FLAG_DATA_CPP ) {
|
||||
if( datakind == DT_FLAG_DATA_COMPLEX )
|
||||
return ompi_ddt_match_size_internal( size, datakind, datalang );
|
||||
datalang = DT_FLAG_DATA_C;
|
||||
}
|
||||
return ompi_ddt_match_size_internal( size, datakind, datalang );
|
||||
}
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user