Corresponding changes to r21641 and r21642 for Windows.
- Add a CMake macro for checking OPAL_MAX_XXX values, re-written from OPAL_WITH_OPTION_MIN_MAX_VALUE m4 function. - Definition prefix changes and additional datatype alignments checking. - Finish the datatype splitting on Windows too. :-) This commit was SVN r21649. The following SVN revision numbers were found above: r21641 --> open-mpi/ompi@6c5532072a r21642 --> open-mpi/ompi@c971c09eb6
Этот коммит содержится в:
родитель
2f552eb8c1
Коммит
503f2817b3
@ -15,6 +15,7 @@
|
|||||||
INCLUDE (get_c_alignment)
|
INCLUDE (get_c_alignment)
|
||||||
INCLUDE (check_c_inline)
|
INCLUDE (check_c_inline)
|
||||||
INCLUDE (Check_c_type_exists)
|
INCLUDE (Check_c_type_exists)
|
||||||
|
INCLUDE (opal_functions)
|
||||||
|
|
||||||
INCLUDE (CheckIncludeFileCXX)
|
INCLUDE (CheckIncludeFileCXX)
|
||||||
INCLUDE (CheckIncludeFile)
|
INCLUDE (CheckIncludeFile)
|
||||||
@ -154,6 +155,26 @@ ENDIF(WIN32 AND MSVC)
|
|||||||
# Options #
|
# Options #
|
||||||
###################################################################
|
###################################################################
|
||||||
|
|
||||||
|
# No lower and upper bound required or enforced
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(processor_name 256 16 1024)
|
||||||
|
|
||||||
|
# Min length according to information passed in ompi/errhandler/errcode.c
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(error_string 256 64 1024)
|
||||||
|
|
||||||
|
# Min length according to MPI-2.1, p. 236 (information passed in ompi/communicator/comm.c: min only 48)
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(object_name 64 64 256)
|
||||||
|
|
||||||
|
# Min and Max length according to MPI-2.1, p. 287 is 32; longest key in ROMIO however 33
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(info_key 36 34 255)
|
||||||
|
|
||||||
|
# No lower and upper bound required or enforced!
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(info_val 256 32 1024)
|
||||||
|
|
||||||
|
# Min length according to _POSIX_HOST_NAME_MAX=255 (4*HOST_NAME_MAX)
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(port_name 1024 255 2048)
|
||||||
|
|
||||||
|
# Min length accroding to MPI-2.1, p. 418
|
||||||
|
OPAL_WITH_OPTION_MIN_MAX_VALUE(datarep_string 128 64 256)
|
||||||
|
|
||||||
OPTION(MCA_mtl_DIRECT_CALL "Whether mtl should use direct calls instead of components." OFF)
|
OPTION(MCA_mtl_DIRECT_CALL "Whether mtl should use direct calls instead of components." OFF)
|
||||||
MARK_AS_ADVANCED(MCA_mtl_DIRECT_CALL)
|
MARK_AS_ADVANCED(MCA_mtl_DIRECT_CALL)
|
||||||
@ -887,6 +908,10 @@ SET(SIZEOF_UNSIGNED_SHORT ${UNSIGNED_SHORT} CACHE INTERNAL "sizeof 'unsigned sho
|
|||||||
CHECK_TYPE_SIZE ("unsigned long long" UNSIGNED_LONG_LONG)
|
CHECK_TYPE_SIZE ("unsigned long long" UNSIGNED_LONG_LONG)
|
||||||
SET(SIZEOF_UNSIGNED_LONG_LONG ${UNSIGNED_LONG_LONG} CACHE INTERNAL "sizeof 'unsigned long long'")
|
SET(SIZEOF_UNSIGNED_LONG_LONG ${UNSIGNED_LONG_LONG} CACHE INTERNAL "sizeof 'unsigned long long'")
|
||||||
|
|
||||||
|
#/* The size of `unsigned long double', as computed by sizeof. */
|
||||||
|
CHECK_TYPE_SIZE("unsigned long double" UNSIGNED_LONG_DOUBLE)
|
||||||
|
SET(SIZEOF_UNSIGNED_LONG_DOUBLE ${UNSIGNED_LONG_DOUBLE} CACHE INTERNAL "sizeof 'unsigned long double'")
|
||||||
|
|
||||||
#/* The size of `unsigned char', as computed by sizeof. */
|
#/* The size of `unsigned char', as computed by sizeof. */
|
||||||
CHECK_TYPE_SIZE ("unsigned char" UNSIGNED_CHAR)
|
CHECK_TYPE_SIZE ("unsigned char" UNSIGNED_CHAR)
|
||||||
SET(SIZEOF_UNSIGNED_CHAR ${UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'unsigned char'")
|
SET(SIZEOF_UNSIGNED_CHAR ${UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'unsigned char'")
|
||||||
@ -895,6 +920,18 @@ SET(SIZEOF_UNSIGNED_CHAR ${UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'unsigned char'
|
|||||||
CHECK_TYPE_SIZE(short SHORT)
|
CHECK_TYPE_SIZE(short SHORT)
|
||||||
SET(SIZEOF_SHORT ${SHORT} CACHE INTERNAL "sizeof 'short'")
|
SET(SIZEOF_SHORT ${SHORT} CACHE INTERNAL "sizeof 'short'")
|
||||||
|
|
||||||
|
#/* The size of `float _Complex', as computed by sizeof. */
|
||||||
|
CHECK_TYPE_SIZE("float _Complex" FLOAT_COMPLEX)
|
||||||
|
SET(SIZEOF_FLOAT_COMPLEX ${SHORT} CACHE INTERNAL "sizeof 'float _Complex'")
|
||||||
|
|
||||||
|
#/* The size of `double _Complex', as computed by sizeof. */
|
||||||
|
CHECK_TYPE_SIZE("double _Complex" DOUBLE_COMPLEX)
|
||||||
|
SET(SIZEOF_DOUBLE_COMPLEX ${SHORT} CACHE INTERNAL "sizeof 'double _Complex'")
|
||||||
|
|
||||||
|
#/* The size of `long double _Complex', as computed by sizeof. */
|
||||||
|
CHECK_TYPE_SIZE("long double _Complex" LONG_DOUBLE_COMPLEX)
|
||||||
|
SET(SIZEOF_LONG_DOUBLE_COMPLEX ${SHORT} CACHE INTERNAL "sizeof 'long double _Complex'")
|
||||||
|
|
||||||
#/* The size of `size_t', as computed by sizeof. */
|
#/* The size of `size_t', as computed by sizeof. */
|
||||||
CHECK_TYPE_SIZE(size_t SIZE_T)
|
CHECK_TYPE_SIZE(size_t SIZE_T)
|
||||||
IF (NOT SIZEOF_SIZE_T)
|
IF (NOT SIZEOF_SIZE_T)
|
||||||
@ -931,14 +968,28 @@ SET(SIZEOF_PTRDIFF_T ${PTRDIFF_T} CACHE INTERNAL "sizeof 'ptrdiff_t'")
|
|||||||
#/* Define to 1 if the system has the type `mode_t'. */
|
#/* Define to 1 if the system has the type `mode_t'. */
|
||||||
CHECK_TYPE_SIZE (mode_t MODE_T)
|
CHECK_TYPE_SIZE (mode_t MODE_T)
|
||||||
|
|
||||||
|
#/* Define to 1 if the system has the type `int8_t'. */
|
||||||
|
CHECK_TYPE_SIZE (int8_t INT8_T)
|
||||||
|
IF (NOT SIZEOF_INT8_T)
|
||||||
|
MESSAGE(STATUS "Define it as 'char'.")
|
||||||
|
C_GET_ALIGNMENT(char c INT8)
|
||||||
|
#SET (int8_t "char" CACHE INTERNAL "define 'int8_t'")
|
||||||
|
SET (SIZEOF_INT8_T ${SIZEOF_UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'int8_t'")
|
||||||
|
ELSEIF (HAVE_INT8_T)
|
||||||
|
C_GET_ALIGNMENT(int8_t c INT8)
|
||||||
|
SET (SIZEOF_INT8_T ${INT8_T} CACHE INTERNAL "sizeof 'int8_t'")
|
||||||
|
ENDIF (NOT SIZEOF_INT8_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `int16_t'. */
|
#/* Define to 1 if the system has the type `int16_t'. */
|
||||||
CHECK_TYPE_SIZE (int16_t INT16_T)
|
CHECK_TYPE_SIZE (int16_t INT16_T)
|
||||||
IF (NOT SIZEOF_INT16_T)
|
IF (NOT SIZEOF_INT16_T)
|
||||||
# int16_t is not defind, define it as short.
|
# int16_t is not defind, define it as short.
|
||||||
MESSAGE(STATUS "Define it as 'short'.")
|
MESSAGE(STATUS "Define it as 'short'.")
|
||||||
|
C_GET_ALIGNMENT(short c INT16)
|
||||||
#SET (int16_t "short" CACHE INTERNAL "define 'int16_t'")
|
#SET (int16_t "short" CACHE INTERNAL "define 'int16_t'")
|
||||||
SET (SIZEOF_INT16_T ${SIZEOF_SHORT} CACHE INTERNAL "sizeof 'int16_t'")
|
SET (SIZEOF_INT16_T ${SIZEOF_SHORT} CACHE INTERNAL "sizeof 'int16_t'")
|
||||||
ELSEIF (HAVE_INT16_T)
|
ELSEIF (HAVE_INT16_T)
|
||||||
|
C_GET_ALIGNMENT(int16_t c INT16)
|
||||||
SET (SIZEOF_INT16_T ${INT16_T} CACHE INTERNAL "sizeof 'int16_t'")
|
SET (SIZEOF_INT16_T ${INT16_T} CACHE INTERNAL "sizeof 'int16_t'")
|
||||||
ENDIF (NOT SIZEOF_INT16_T)
|
ENDIF (NOT SIZEOF_INT16_T)
|
||||||
|
|
||||||
@ -946,9 +997,11 @@ ENDIF (NOT SIZEOF_INT16_T)
|
|||||||
CHECK_TYPE_SIZE (int32_t INT32_T)
|
CHECK_TYPE_SIZE (int32_t INT32_T)
|
||||||
IF (NOT SIZEOF_INT32_T)
|
IF (NOT SIZEOF_INT32_T)
|
||||||
MESSAGE(STATUS "Define it as 'int'.")
|
MESSAGE(STATUS "Define it as 'int'.")
|
||||||
|
C_GET_ALIGNMENT(int c INT32)
|
||||||
#SET (int32_t "int" CACHE INTERNAL "define 'int32_t'")
|
#SET (int32_t "int" CACHE INTERNAL "define 'int32_t'")
|
||||||
SET (SIZEOF_INT32_T ${SIZEOF_INT} CACHE INTERNAL "sizeof 'int32_t'")
|
SET (SIZEOF_INT32_T ${SIZEOF_INT} CACHE INTERNAL "sizeof 'int32_t'")
|
||||||
ELSEIF (HAVE_INT32_T)
|
ELSEIF (HAVE_INT32_T)
|
||||||
|
C_GET_ALIGNMENT(int32_t c INT32)
|
||||||
SET (SIZEOF_INT32_T ${INT32_T} CACHE INTERNAL "sizeof 'int32_t'")
|
SET (SIZEOF_INT32_T ${INT32_T} CACHE INTERNAL "sizeof 'int32_t'")
|
||||||
ENDIF (NOT SIZEOF_INT32_T)
|
ENDIF (NOT SIZEOF_INT32_T)
|
||||||
|
|
||||||
@ -956,21 +1009,35 @@ ENDIF (NOT SIZEOF_INT32_T)
|
|||||||
CHECK_TYPE_SIZE (int64_t INT64_T)
|
CHECK_TYPE_SIZE (int64_t INT64_T)
|
||||||
IF (NOT SIZEOF_INT64_T)
|
IF (NOT SIZEOF_INT64_T)
|
||||||
MESSAGE(STATUS "Define it as 'long long'.")
|
MESSAGE(STATUS "Define it as 'long long'.")
|
||||||
|
C_GET_ALIGNMENT("long long" c INT64)
|
||||||
#SET (int64_t "long long" CACHE INTERNAL "define 'int64_t'")
|
#SET (int64_t "long long" CACHE INTERNAL "define 'int64_t'")
|
||||||
SET (SIZEOF_INT64_T ${SIZEOF_LONG_LONG} CACHE INTERNAL "sizeof 'int64_t'")
|
SET (SIZEOF_INT64_T ${SIZEOF_LONG_LONG} CACHE INTERNAL "sizeof 'int64_t'")
|
||||||
ELSEIF (HAVE_INT64_T)
|
ELSEIF (HAVE_INT64_T)
|
||||||
|
C_GET_ALIGNMENT(int64_t c INT64)
|
||||||
SET (SIZEOF_INT64_T ${INT64_T} CACHE INTERNAL "sizeof 'int64_t'")
|
SET (SIZEOF_INT64_T ${INT64_T} CACHE INTERNAL "sizeof 'int64_t'")
|
||||||
ENDIF (NOT SIZEOF_INT64_T)
|
ENDIF (NOT SIZEOF_INT64_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `int8_t'. */
|
#/* Define to 1 if the system has the type `int128_t'. */
|
||||||
CHECK_TYPE_SIZE (int8_t INT8_T)
|
CHECK_TYPE_SIZE (int128_t INT128_T)
|
||||||
IF (NOT SIZEOF_INT8_T)
|
IF (NOT SIZEOF_INT128_T)
|
||||||
MESSAGE(STATUS "Define it as 'char'.")
|
MESSAGE(STATUS "Define it as 'long double'.")
|
||||||
#SET (int8_t "char" CACHE INTERNAL "define 'int8_t'")
|
C_GET_ALIGNMENT("long double" c INT128)
|
||||||
SET (SIZEOF_INT8_T ${SIZEOF_UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'int8_t'")
|
#SET (u_int8_t "unsigned char" CACHE INTERNAL "define 'uint8_t'")
|
||||||
|
SET (SIZEOF_INT128_T ${SIZEOF_LONG_DOUBLE} CACHE INTERNAL "sizeof 'int128_t'")
|
||||||
ELSEIF (HAVE_INT8_T)
|
ELSEIF (HAVE_INT8_T)
|
||||||
SET (SIZEOF_INT8_T ${INT8_T} CACHE INTERNAL "sizeof 'int8_t'")
|
C_GET_ALIGNMENT(int128_t c INT128)
|
||||||
ENDIF (NOT SIZEOF_INT8_T)
|
SET (SIZEOF_INT128_T ${INT128_T} CACHE INTERNAL "sizeof 'int128_t'")
|
||||||
|
ENDIF (NOT SIZEOF_INT128_T)
|
||||||
|
|
||||||
|
#/* Define to 1 if the system has the type `uint8_t'. */
|
||||||
|
CHECK_TYPE_SIZE (uint8_t UINT8_T)
|
||||||
|
IF (NOT SIZEOF_UINT8_T)
|
||||||
|
MESSAGE(STATUS "Define it as 'unsigned char'.")
|
||||||
|
#SET (u_int8_t "unsigned char" CACHE INTERNAL "define 'uint8_t'")
|
||||||
|
SET (SIZEOF_UINT8_T ${SIZEOF_UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'uint8_t'")
|
||||||
|
ELSEIF (HAVE_UINT8_T)
|
||||||
|
SET (SIZEOF_UINT8_T ${UINT8_T} CACHE INTERNAL "sizeof 'uint8_t'")
|
||||||
|
ENDIF (NOT SIZEOF_UINT8_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `uint16_t'. */
|
#/* Define to 1 if the system has the type `uint16_t'. */
|
||||||
CHECK_TYPE_SIZE (uint16_t UINT16_T)
|
CHECK_TYPE_SIZE (uint16_t UINT16_T)
|
||||||
@ -983,34 +1050,34 @@ ELSEIF (HAVE_UINT16_T)
|
|||||||
ENDIF (NOT SIZEOF_UINT16_T)
|
ENDIF (NOT SIZEOF_UINT16_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `uint32_t'. */
|
#/* Define to 1 if the system has the type `uint32_t'. */
|
||||||
CHECK_TYPE_SIZE (uint32_t UNIT32_T)
|
CHECK_TYPE_SIZE (uint32_t UINT32_T)
|
||||||
IF (NOT SIZEOF_UINT32_T)
|
IF (NOT SIZEOF_UINT32_T)
|
||||||
MESSAGE(STATUS "Define it as 'unsigned int'.")
|
MESSAGE(STATUS "Define it as 'unsigned int'.")
|
||||||
#SET (u_int32_t "unsigned int" CACHE INTERNAL "define 'uint32_t'")
|
#SET (u_int32_t "unsigned int" CACHE INTERNAL "define 'uint32_t'")
|
||||||
SET (SIZEOF_UINT32_T ${SIZEOF_UNSIGNED_INT} CACHE INTERNAL "sizeof 'uint32_t'")
|
SET (SIZEOF_UINT32_T ${SIZEOF_UNSIGNED_INT} CACHE INTERNAL "sizeof 'uint32_t'")
|
||||||
ELSEIF (HAVE_UINT32_T)
|
ELSEIF (HAVE_UINT32_T)
|
||||||
SET (SIZEOF_UINT32_T ${UNIT32_T} CACHE INTERNAL "sizeof 'uint32_t'")
|
SET (SIZEOF_UINT32_T ${UINT32_T} CACHE INTERNAL "sizeof 'uint32_t'")
|
||||||
ENDIF (NOT SIZEOF_UINT32_T)
|
ENDIF (NOT SIZEOF_UINT32_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `uint64_t'. */
|
#/* Define to 1 if the system has the type `uint64_t'. */
|
||||||
CHECK_TYPE_SIZE (unit64_t UNIT64_T)
|
CHECK_TYPE_SIZE (uint64_t UINT64_T)
|
||||||
IF (NOT SIZEOF_UINT64_T)
|
IF (NOT SIZEOF_UINT64_T)
|
||||||
MESSAGE(STATUS "Define it as 'unsigned long long'.")
|
MESSAGE(STATUS "Define it as 'unsigned long long'.")
|
||||||
#SET (u_int64_t "unsigned long long" CACHE INTERNAL "define 'uint64_t'")
|
#SET (u_int64_t "unsigned long long" CACHE INTERNAL "define 'uint64_t'")
|
||||||
SET (SIZEOF_UINT64_T ${SIZEOF_UNSIGNED_LONG_LONG} CACHE INTERNAL "sizeof 'uint64_t'")
|
SET (SIZEOF_UINT64_T ${SIZEOF_UNSIGNED_LONG_LONG} CACHE INTERNAL "sizeof 'uint64_t'")
|
||||||
ELSEIF (HAVE_UINT64_T)
|
ELSEIF (HAVE_UINT64_T)
|
||||||
SET (SIZEOF_UINT64_T ${UNIT64_T} CACHE INTERNAL "sizeof 'uint64_t'")
|
SET (SIZEOF_UINT64_T ${UINT64_T} CACHE INTERNAL "sizeof 'uint64_t'")
|
||||||
ENDIF (NOT SIZEOF_UINT64_T)
|
ENDIF (NOT SIZEOF_UINT64_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `uint8_t'. */
|
#/* Define to 1 if the system has the type `uint128_t'. */
|
||||||
CHECK_TYPE_SIZE (unit8_t UNIT8_T)
|
CHECK_TYPE_SIZE (uint128_t UINT128_T)
|
||||||
IF (NOT SIZEOF_UINT8_T)
|
IF (NOT SIZEOF_UINT128_T)
|
||||||
MESSAGE(STATUS "Define it as 'unsigned char'.")
|
MESSAGE(STATUS "Define it as 'unsigned long double'.")
|
||||||
#SET (u_int8_t "unsigned char" CACHE INTERNAL "define 'uint8_t'")
|
#SET (u_int8_t "unsigned char" CACHE INTERNAL "define 'uint8_t'")
|
||||||
SET (SIZEOF_UINT8_T ${SIZEOF_UNSIGNED_CHAR} CACHE INTERNAL "sizeof 'uint8_t'")
|
SET (SIZEOF_UINT128_T ${SIZEOF_UNSIGNED_LONG_DOUBLE} CACHE INTERNAL "sizeof 'uint128_t'")
|
||||||
ELSEIF (HAVE_UINT8_T)
|
ELSEIF (HAVE_UINT8_T)
|
||||||
SET (SIZEOF_UINT8_T ${UNIT8_T} CACHE INTERNAL "sizeof 'uint8_t'")
|
SET (SIZEOF_UINT128_T ${UINT128_T} CACHE INTERNAL "sizeof 'uint128_t'")
|
||||||
ENDIF (NOT SIZEOF_UINT8_T)
|
ENDIF (NOT SIZEOF_UINT128_T)
|
||||||
|
|
||||||
#/* Define to 1 if the system has the type `struct sockaddr_in'. */
|
#/* Define to 1 if the system has the type `struct sockaddr_in'. */
|
||||||
CHECK_TYPE_SIZE ("struct sockaddr_in" STRUCT_SOCKADDR_IN)
|
CHECK_TYPE_SIZE ("struct sockaddr_in" STRUCT_SOCKADDR_IN)
|
||||||
@ -1051,12 +1118,27 @@ C_GET_ALIGNMENT ("long long" c LONG_LONG)
|
|||||||
#/* Alignment of type short */
|
#/* Alignment of type short */
|
||||||
C_GET_ALIGNMENT (short c SHORT)
|
C_GET_ALIGNMENT (short c SHORT)
|
||||||
|
|
||||||
|
IF(HAVE_FLOAT_COMPLEX)
|
||||||
|
C_GET_ALIGNMENT("float _Complex" c FLOAT_COMPLEX)
|
||||||
|
ENDIF(HAVE_FLOAT_COMPLEX)
|
||||||
|
|
||||||
|
IF(HAVE_DOUBLE_COMPLEX)
|
||||||
|
C_GET_ALIGNMENT("double _Complex" c DOUBLE_COMPLEX)
|
||||||
|
ENDIF(HAVE_DOUBLE_COMPLEX)
|
||||||
|
|
||||||
|
IF(HAVE_LONG_DOUBLE_COMPLEX)
|
||||||
|
C_GET_ALIGNMENT("long double _Complex" c LONG_DOUBLE_COMPLEX)
|
||||||
|
ENDIF(HAVE_LONG_DOUBLE_COMPLEX)
|
||||||
|
|
||||||
#/* Alignment of type void * */
|
#/* Alignment of type void * */
|
||||||
C_GET_ALIGNMENT ("void *" c VOID_P)
|
C_GET_ALIGNMENT ("void *" c VOID_P)
|
||||||
|
|
||||||
#/* Alignment of type wchar_t */
|
#/* Alignment of type wchar_t */
|
||||||
C_GET_ALIGNMENT (wchar_t c WCHAR_T)
|
C_GET_ALIGNMENT (wchar_t c WCHAR_T)
|
||||||
|
|
||||||
|
#/* Alignment of type _Bool */
|
||||||
|
C_GET_ALIGNMENT(_Bool, c BOOL)
|
||||||
|
|
||||||
#/* Whether the C compiler supports "bool" without any other help (such as
|
#/* Whether the C compiler supports "bool" without any other help (such as
|
||||||
# <stdbool.h>) */
|
# <stdbool.h>) */
|
||||||
INCLUDE(c_check_bool)
|
INCLUDE(c_check_bool)
|
||||||
@ -1864,3 +1946,13 @@ SET (PACKAGE_VERSION ${VERSION_STRING})
|
|||||||
# SET(ompi_fortran_real_t 1)
|
# SET(ompi_fortran_real_t 1)
|
||||||
# SET(ompi_fortran_real_t_STRING "ompi_fortran_bogus_type_t")
|
# SET(ompi_fortran_real_t_STRING "ompi_fortran_bogus_type_t")
|
||||||
#ENDIF(WIN32)
|
#ENDIF(WIN32)
|
||||||
|
|
||||||
|
#
|
||||||
|
# User level (mpi.h.in) visible maximum lengths of strings.
|
||||||
|
# These may be required in lower-level libraries to set up matching
|
||||||
|
# data-structures (e.g. OPAL_MAX_OBJECT_NAME).
|
||||||
|
#
|
||||||
|
# Default values (as of OMPI-1.3), and some sane minimum and maximum values
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
52
contrib/platform/win32/CMakeModules/opal_functions.cmake
Обычный файл
52
contrib/platform/win32/CMakeModules/opal_functions.cmake
Обычный файл
@ -0,0 +1,52 @@
|
|||||||
|
#
|
||||||
|
# Copyright (c) 2009 High Performance Computing Center Stuttgart,
|
||||||
|
# University of Stuttgart. All rights reserved.
|
||||||
|
# $COPYRIGHT$
|
||||||
|
#
|
||||||
|
# Additional copyrights may follow
|
||||||
|
#
|
||||||
|
# $HEADER$
|
||||||
|
#
|
||||||
|
|
||||||
|
#
|
||||||
|
# Functions that are re-written from config/opal_functions.m4, and to be continued...
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
# OPAL_WITH_OPTION_MIN_MAX_VALUE(NAME,DEFAULT_VALUE,LOWER_BOUND,UPPER_BOUND)
|
||||||
|
# Defines a variable OPAL_MAX_xxx, with "xxx" being specified as the first parameter.
|
||||||
|
# If not set at configure-time, the default-value is assumed.
|
||||||
|
# If set, value is checked against lower and upper bound
|
||||||
|
#
|
||||||
|
MACRO(OPAL_WITH_OPTION_MIN_MAX_VALUE NAME DEFAULT_VALUE LOWER_BOUND UPPER_BOUND)
|
||||||
|
|
||||||
|
STRING(REPLACE "_" " " NAME_HELPER ${NAME})
|
||||||
|
STRING(TOUPPER "OPAL_MAX_${NAME}" OPTION_VALUE_VAR)
|
||||||
|
|
||||||
|
IF(NOT ${OPTION_VALUE_VAR})
|
||||||
|
MESSAGE(STATUS "checking maximum length of ${NAME_HELPER}...")
|
||||||
|
MESSAGE(STATUS "Use default value ${DEFAULT_VALUE}.")
|
||||||
|
|
||||||
|
SET(${NAME}_OLD_VALUE ${DEFAULT_VALUE} CACHE INTERNAL "the value from the last configure.")
|
||||||
|
SET(${OPTION_VALUE_VAR} ${DEFAULT_VALUE} CACHE STRING
|
||||||
|
"maximum length of ${NAME} (${LOWER_BOUND}-${UPPER_BOUND}). (Default: ${DEFAULT_VALUE}.)." FORCE)
|
||||||
|
ENDIF(NOT ${OPTION_VALUE_VAR})
|
||||||
|
|
||||||
|
# check if the value is changed.
|
||||||
|
IF(NOT ${${OPTION_VALUE_VAR}} EQUAL ${NAME}_OLD_VALUE)
|
||||||
|
MESSAGE(STATUS "checking maximum length of ${NAME_HELPER}...")
|
||||||
|
|
||||||
|
# check if the value is in the range.
|
||||||
|
IF(NOT ${${OPTION_VALUE_VAR}} EQUAL 0 AND NOT ${${OPTION_VALUE_VAR}} EQUAL no AND NOT ${${OPTION_VALUE_VAR}} EQUAL NO)
|
||||||
|
|
||||||
|
IF(${${OPTION_VALUE_VAR}} LESS ${LOWER_BOUND} OR ${${OPTION_VALUE_VAR}} GREATER ${UPPER_BOUND})
|
||||||
|
MESSAGE(FATAL_ERROR "${OPTION_VALUE_VAR} is out of range(${LOWER_BOUND}-${UPPER_BOUND}). Cannot continue.")
|
||||||
|
ENDIF(${${OPTION_VALUE_VAR}} LESS ${LOWER_BOUND} OR ${${OPTION_VALUE_VAR}} GREATER ${UPPER_BOUND})
|
||||||
|
|
||||||
|
ELSE(NOT ${${OPTION_VALUE_VAR}} EQUAL 0 AND NOT ${${OPTION_VALUE_VAR}} EQUAL no AND NOT ${${OPTION_VALUE_VAR}} EQUAL NO)
|
||||||
|
MESSAGE(FATAL_ERROR "Bad value for ${OPTION_VALUE_VAR}. Cannot continue.")
|
||||||
|
ENDIF(NOT ${${OPTION_VALUE_VAR}} EQUAL 0 AND NOT ${${OPTION_VALUE_VAR}} EQUAL no AND NOT ${${OPTION_VALUE_VAR}} EQUAL NO)
|
||||||
|
|
||||||
|
ENDIF(NOT ${${OPTION_VALUE_VAR}} EQUAL ${NAME}_OLD_VALUE)
|
||||||
|
|
||||||
|
ENDMACRO(OPAL_WITH_OPTION_MIN_MAX_VALUE NAME DEFAULT_VALUE LOWER_BOUND UPPER_BOUND)
|
@ -6,7 +6,7 @@
|
|||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
* Copyright (c) 2004-2008 High Performance Computing Center Stuttgart,
|
* Copyright (c) 2004-2009 High Performance Computing Center Stuttgart,
|
||||||
* University of Stuttgart. All rights reserved.
|
* University of Stuttgart. All rights reserved.
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
* Copyright (c) 2004-2005 The Regents of the University of California.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
@ -63,6 +63,27 @@
|
|||||||
|
|
||||||
#define OPAL_BUILD_PLATFORM_COMPILER_VERSION_STR ${COMPILER_VERSION}
|
#define OPAL_BUILD_PLATFORM_COMPILER_VERSION_STR ${COMPILER_VERSION}
|
||||||
|
|
||||||
|
/* Maximum length of datarep strings (default is 128) */
|
||||||
|
#define OPAL_MAX_DATAREP_STRING ${OPAL_MAX_DATAREP_STRING}
|
||||||
|
|
||||||
|
/* Maximum length of error strings (default is 256) */
|
||||||
|
#define OPAL_MAX_ERROR_STRING ${OPAL_MAX_ERROR_STRING}
|
||||||
|
|
||||||
|
/* Maximum length of info keys (default is 36) */
|
||||||
|
#define OPAL_MAX_INFO_KEY ${OPAL_MAX_INFO_KEY}
|
||||||
|
|
||||||
|
/* Maximum length of info vals (default is 256) */
|
||||||
|
#define OPAL_MAX_INFO_VAL ${OPAL_MAX_INFO_VAL}
|
||||||
|
|
||||||
|
/* Maximum length of object names (default is 64) */
|
||||||
|
#define OPAL_MAX_OBJECT_NAME ${OPAL_MAX_OBJECT_NAME}
|
||||||
|
|
||||||
|
/* Maximum length of port names (default is 1024) */
|
||||||
|
#define OPAL_MAX_PORT_NAME ${OPAL_MAX_PORT_NAME}
|
||||||
|
|
||||||
|
/* Maximum length of processor names (default is 256) */
|
||||||
|
#define OPAL_MAX_PROCESSOR_NAME ${OPAL_MAX_PROCESSOR_NAME}
|
||||||
|
|
||||||
/* Define to 1 if you have the <winsock2.h> header file. */
|
/* Define to 1 if you have the <winsock2.h> header file. */
|
||||||
#cmakedefine HAVE_WINSOCK2_H 1
|
#cmakedefine HAVE_WINSOCK2_H 1
|
||||||
|
|
||||||
@ -641,13 +662,13 @@
|
|||||||
#define OPAL_ALIGNMENT_CHAR ${CHAR_ALIGNMENT}
|
#define OPAL_ALIGNMENT_CHAR ${CHAR_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of type bool */
|
/* Alignment of type bool */
|
||||||
#define OMPI_ALIGNMENT_CXX_BOOL ${BOOL_ALIGNMENT}
|
#define OPAL_ALIGNMENT_CXX_BOOL ${BOOL_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of type double */
|
/* Alignment of type double */
|
||||||
#define OMPI_ALIGNMENT_DOUBLE ${DOUBLE_ALIGNMENT}
|
#define OPAL_ALIGNMENT_DOUBLE ${DOUBLE_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of type float */
|
/* Alignment of type float */
|
||||||
#define OMPI_ALIGNMENT_FLOAT ${FLOAT_ALIGNMENT}
|
#define OPAL_ALIGNMENT_FLOAT ${FLOAT_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of Fortran 77 COMPLEX */
|
/* Alignment of Fortran 77 COMPLEX */
|
||||||
#define OMPI_ALIGNMENT_FORTRAN_COMPLEX ${OMPI_ALIGNMENT_FORTRAN_COMPLEX}
|
#define OMPI_ALIGNMENT_FORTRAN_COMPLEX ${OMPI_ALIGNMENT_FORTRAN_COMPLEX}
|
||||||
@ -727,11 +748,38 @@
|
|||||||
/* Alignment of type short */
|
/* Alignment of type short */
|
||||||
#define OPAL_ALIGNMENT_SHORT ${SHORT_ALIGNMENT}
|
#define OPAL_ALIGNMENT_SHORT ${SHORT_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type float _Complex */
|
||||||
|
#cmakedefine OPAL_ALIGNMENT_FLOAT_COMPLEX ${FLOAT_COMPLEX_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type double _Complex */
|
||||||
|
#cmakedefine OPAL_ALIGNMENT_DOUBLE_COMPLEX ${DOUBLE_COMPLEX_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type long double _Complex */
|
||||||
|
#cmakedefine OPAL_ALIGNMENT_LONG_DOUBLE_COMPLEX ${LONG_DOUBLE_COMPLEX_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of type void * */
|
/* Alignment of type void * */
|
||||||
#define OMPI_ALIGNMENT_VOID_P ${VOID_P_ALIGNMENT}
|
#define OPAL_ALIGNMENT_VOID_P ${VOID_P_ALIGNMENT}
|
||||||
|
|
||||||
/* Alignment of type wchar_t */
|
/* Alignment of type wchar_t */
|
||||||
#define OMPI_ALIGNMENT_WCHAR ${WCHAR_T_ALIGNMENT}
|
#define OPAL_ALIGNMENT_WCHAR ${WCHAR_T_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type _Bool */
|
||||||
|
#define OPAL_ALIGNMENT_BOOL ${BOOL_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type wchar_t */
|
||||||
|
#define OPAL_ALIGNMENT_INT8 ${INT8_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type wchar_t */
|
||||||
|
#define OPAL_ALIGNMENT_INT16 ${INT16_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type wchar_t */
|
||||||
|
#define OPAL_ALIGNMENT_INT32 ${INT32_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type wchar_t */
|
||||||
|
#define OPAL_ALIGNMENT_INT64 ${INT64_ALIGNMENT}
|
||||||
|
|
||||||
|
/* Alignment of type wchar_t */
|
||||||
|
#define OPAL_ALIGNMENT_INT128 ${INT128_ALIGNMENT}
|
||||||
|
|
||||||
/* OMPI architecture string */
|
/* OMPI architecture string */
|
||||||
#define OPAL_ARCH "${CMAKE_SYSTEM_PROCESSOR} ${CMAKE_SYSTEM}"
|
#define OPAL_ARCH "${CMAKE_SYSTEM_PROCESSOR} ${CMAKE_SYSTEM}"
|
||||||
|
@ -17,19 +17,6 @@
|
|||||||
|
|
||||||
PROJECT (OMPI)
|
PROJECT (OMPI)
|
||||||
|
|
||||||
# These two files need to be compiled twice, one time with preprocessor CHECKSUM.
|
|
||||||
# Make one copy of them with another file name and add them into the project.
|
|
||||||
CONFIGURE_FILE(datatype/datatype_pack.c ${PROJECT_BINARY_DIR}/datatype/datatype_pack_checksum.c [COPYONLY])
|
|
||||||
CONFIGURE_FILE(datatype/datatype_unpack.c ${PROJECT_BINARY_DIR}/datatype/datatype_unpack_checksum.c [COPYONLY])
|
|
||||||
|
|
||||||
SET(DATATYPE_CHECKSUM_FILES ${PROJECT_BINARY_DIR}/datatype/datatype_pack_checksum.c
|
|
||||||
${PROJECT_BINARY_DIR}/datatype/datatype_unpack_checksum.c )
|
|
||||||
|
|
||||||
SET_SOURCE_FILES_PROPERTIES(${DATATYPE_CHECKSUM_FILES}
|
|
||||||
PROPERTIES COMPILE_DEFINITIONS CHECKSUM)
|
|
||||||
SET(OMPI_SOURCE_FILES ${OMPI_SOURCE_FILES} ${DATATYPE_CHECKSUM_FILES})
|
|
||||||
SOURCE_GROUP(datatype FILES ${DATATYPE_CHECKSUM_FILES})
|
|
||||||
|
|
||||||
# Recuresive search sub directories excluding mca, mpi and tools.
|
# Recuresive search sub directories excluding mca, mpi and tools.
|
||||||
# Add sources in different source groups.
|
# Add sources in different source groups.
|
||||||
EXECUTE_PROCESS (COMMAND cmd /C dir /AD /B
|
EXECUTE_PROCESS (COMMAND cmd /C dir /AD /B
|
||||||
|
@ -15,6 +15,19 @@ PROJECT (OPAL)
|
|||||||
# Add include sub directory to gernerate opal_config.h
|
# Add include sub directory to gernerate opal_config.h
|
||||||
ADD_SUBDIRECTORY (include)
|
ADD_SUBDIRECTORY (include)
|
||||||
|
|
||||||
|
# These two files need to be compiled twice, one time with preprocessor CHECKSUM.
|
||||||
|
# Make one copy of them with another file name and add them into the project.
|
||||||
|
CONFIGURE_FILE(datatype/opal_datatype_pack.c ${PROJECT_BINARY_DIR}/datatype/opal_datatype_pack_checksum.c [COPYONLY])
|
||||||
|
CONFIGURE_FILE(datatype/opal_datatype_unpack.c ${PROJECT_BINARY_DIR}/datatype/opal_datatype_unpack_checksum.c [COPYONLY])
|
||||||
|
|
||||||
|
SET(DATATYPE_CHECKSUM_FILES ${PROJECT_BINARY_DIR}/datatype/opal_datatype_pack_checksum.c
|
||||||
|
${PROJECT_BINARY_DIR}/datatype/opal_datatype_unpack_checksum.c )
|
||||||
|
|
||||||
|
SET_SOURCE_FILES_PROPERTIES(${DATATYPE_CHECKSUM_FILES}
|
||||||
|
PROPERTIES COMPILE_DEFINITIONS CHECKSUM)
|
||||||
|
SET(OPAL_SOURCE_FILES ${OPAL_SOURCE_FILES} ${DATATYPE_CHECKSUM_FILES})
|
||||||
|
SOURCE_GROUP(datatype FILES ${DATATYPE_CHECKSUM_FILES})
|
||||||
|
|
||||||
|
|
||||||
# Add source files
|
# Add source files
|
||||||
|
|
||||||
|
@ -210,6 +210,7 @@ typedef unsigned int uint;
|
|||||||
|
|
||||||
#define sigset_t int
|
#define sigset_t int
|
||||||
#define in_addr_t uint32_t
|
#define in_addr_t uint32_t
|
||||||
|
#define _Bool BOOL
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* No syslog.h on Windows, but these have to be defined somehow.
|
* No syslog.h on Windows, but these have to be defined somehow.
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user