Skip to content

Commit

Permalink
Update fpm_meta.f90
Browse files Browse the repository at this point in the history
  • Loading branch information
perazz committed Dec 13, 2023
1 parent 14d4743 commit 7e8cb16
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions src/fpm_meta.f90
Original file line number Diff line number Diff line change
Expand Up @@ -1098,8 +1098,8 @@ subroutine mpi_compiler_match(language,wrappers,compiler,which_one,mpilib,error)
! Because the intel mpi library does not support llvm_ compiler wrappers yet,
! we must check for that manually
if (mpi_compiler%is_intel() .and. compiler%is_intel()) then
which_one = i
return
same_vendor = i
vendor_mpilib = mpilib
end if

case (LANG_C)
Expand All @@ -1111,9 +1111,9 @@ subroutine mpi_compiler_match(language,wrappers,compiler,which_one,mpilib,error)

! Because the intel mpi library does not support llvm_ compiler wrappers yet,
! we must check for that manually
if (screen%s='icc' .and. compiler%cc=='icx') then
which_one = i
return
if (screen%s=='icc' .and. compiler%cc=='icx') then
same_vendor = i
vendor_mpilib = mpilib
end if

case (LANG_CXX)
Expand All @@ -1124,15 +1124,21 @@ subroutine mpi_compiler_match(language,wrappers,compiler,which_one,mpilib,error)

! Because the intel mpi library does not support llvm_ compiler wrappers yet,
! we must check for that manually
if (screen%s='icpc' .and. compiler%cc=='icpx') then
which_one = i
return
if (screen%s=='icpc' .and. compiler%cc=='icpx') then
same_vendor = i
vendor_mpilib = mpilib
end if

end select

end do

! Intel compiler: if an exact match is not found, attempt closest wrapper
if (which_one==0 .and. same_vendor>0) then
which_one = same_vendor
mpilib = vendor_mpilib
end if

! None of the available wrappers matched the current Fortran compiler
write(msg_out,1) size(wrappers),compiler%fc
call fatal_error(error,trim(msg_out))
Expand Down

0 comments on commit 7e8cb16

Please sign in to comment.