Skip to content

Commit 249420f

Browse files
committed
mtl/ofi: Only compile if ofi version >= 1.9 and cuda requested
If cuda is requested, due to libfabric only supporting FI_HMEM hints in libfabric versions 1.9.0 and greater, we do not compile the ofi mtl if cuda support is requested. Signed-off-by: William Zhang <wilzhang@amazon.com>
1 parent b17cb01 commit 249420f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

ompi/mca/mtl/ofi/configure.m4

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,17 @@ AC_DEFUN([MCA_ompi_mtl_ofi_CONFIG],[
2828
# Check for OFI
2929
OPAL_CHECK_OFI
3030

31+
# Check for CUDA
32+
OPAL_CHECK_CUDA
33+
34+
# Check for cuda support. If so, we require a minimum libfabric version
35+
# of 1.9. FI_HMEM capabilities are only available starting from v1.9
36+
opal_ofi_happy="yes"
37+
AS_IF([test "$opal_check_cuda_happy" = "yes"],
38+
[OPAL_CHECK_OFI_VERSION_GE([1,9],
39+
[],
40+
[opal_ofi_happy=no])])
41+
3142
# The OFI MTL requires at least OFI libfabric v1.5.
3243
AS_IF([test "$opal_ofi_happy" = "yes"],
3344
[OPAL_CHECK_OFI_VERSION_GE([1,5],

0 commit comments

Comments
 (0)