MPL exports additional CFLAGS as MPL_CFLAGS. Only the ones that added
by the MPL configure will be passed. The PAC_CONFIG_MPL macro will add
them to CFLAGS.
PGI compilers, now nvc, spits many warnings by default, some of them
not worth to fix. For an example, the warning,
branch_past_initialization force splitting declaring and initializing
local variables with local scopes.
Suppress them by options instead.
ISO_C_BINDING is an intrisic feature added since Fortran 2003. Check
this feature so we can provide the generic interface using Type(c_ptr),
e.g. in MPI_Alloc_mem.
The HAVE_ROMIO macro is defined in mpichconf.h, not available in
mpicxx.h. Instead, use autoconf macro HAVE_CXX_IO and do substitution
into "#if 1" or "#if 0" at configure time.
The PAC_HAVE_ROMIO macro is called inside the enable_romio branch, thus
won't work with --disable_romio. It is simple enough to put in
configure.ac directly.
Add a call to CFI_is_contiguous, which is needed by the f08
binding. Some compilers provide this prototype, but not the symbol, so
we need to disable f08 if the test fails to link.
Fixespmodels/mpich#6505
Import the same mechanism of compile cu files from yaksa using the
helper script cudalt.sh. We removed the libtool version check because
the mechanism of directly invoking $(libtool) is not stable and libtool
doesn't really check the exact versions.
The compiler may support the weak alias attribute but still broken by
the linker. This is the case e.g. on Cygwin. Use AC_LINK_IFELSE for more
robutst check.
Remove the check for just the attribute weak or weak_import, since both
are not used.
Some of confdb macros are used in both mpich configure and submodules'
configure and they need behave differently. Defining MPICH_CONFIGURE to
reliably identify whether the macros is invoked under mpich's configure.
Some libraries may use different lib names for different forks. Allow
multiple libs to be checked with PAC_CHECK_HEADER_LIB_OPTIONAL. We can't
use AC_SERCH_LIBS because we need know which library actually gets
linked.
The AC_CHECK_SIZEOF or PAC_PROG_F77_CHECK_SIZEOF_EXT should set the type
len to 0 if the type is missing. But sometime the len may end up empty
due some negligence. Make the configure functions behave in this case
rather than leading to mysterious behaviors.
We can't always skip linking libmpl.la when we are install pmi
separately. Use shell variable $pac_skip_mpl_lib instead of m4 macro
PAC_SKIP_MPL_LIB.
Just use PAC_CONFIG_MPL, which should take care of all paths.
When building romio within mpich, we only need set mpl_includedir since
libmpl is included in mpich already. Define and use a specific m4 macro,
PAC_SKIP_MPL_LIB, for this purpose rather than making the exception
based on AC_PACKAGE_NAME. This easily allows additional package, e.g.
pmi, to do the same.
Hydra is going to inherit the CFLAGS from mpich configure. Meanwhile,
having the extra interaction between MPICH and hydra is easy to bring
forth complications. Thus we remove PAC_CC_STRICT from hydra to keep it
simple.
When user has an outdated hwloc installed, the configure will switch to
use the embedded hwloc. This may end up hydra check with embedded hwloc
-- due to inheriting CPPFLAGS from mpich -- and link with external
outdated hwloc. Pass --with-hwloc=embedded option down will prevent such
inconsistency.
We believe it is uncommon to have a system without Python 3. But in case
it is unavailable, one still can manually run e.g. `python3
maint/gen_binding_f08.py` separately to proceed, with the caveat that
they need know the options if the default doesn't work.
Also rename the variable "cmd" into "cmd_f08" to prevent collision with
other parts of configure.
While gcc always compile into PIE objects, other compilers may switch
it off, for example, clang under -O2. This prevents linking with
Fortran, which apparently requires PIE objects.
When using embedded modules, check whether the corresponding convenience
library already exists and skip the configure if it does.
Note: the prebuilt module Makefiles contains absolute paths that may be
different from the current working dir. Thus we have to remove the
module subdir from the Makefile as well. This works as long as we do not
need to re-configure the pre-built submodules. If we ever need to
re-configure submodules, simply remove the la files, e.g.
find modules '*.la' | xargs rm
and rerun configure.
MPL may set additional CPPFLAGS and other variables that need be sourced
into the caller configure script.
Now that romio also calls PAC_CONFIG_MPL, we need make sure it doesn't
link libmpl.la again since mpich already links it.
Since intel compiler (and some other) doesn't support this option and we
need clean for intel compiler anyway, we should clean this warning
rather than exempt from it.
Define and use macros such as PAC_SET_MPI_TYPE to make code cleaner.
Organize the code that configures MPI datatypes. Use following order --
* Check Datatype Sizes and Alignment
* C types using AC_CHECK_SIZEOF
* Fortran types using PAC_PROG_F77_CHECK_SIZEOF_EXT
* For optional types, if not available or disabled, set sizes to 0
* Set sizes for MPI_AINT, MPI_OFFSET, and MPI_COUNT
* Use PAC_SET_MPI_TYPE set basic datatype values
* MPI_{TYPE} for hexadecimal values to be replaced in mpi.h.in
* F77_MPI_{TYPE} for decimal values to be replaced in mpif.h.in
* F08_MPI_{TYPE} for decimal values to be replaced in
mpi_f08_compile_constants.f90.in
Refactor configure of hwloc into confdb/aclocal_modules.m4. We'll factor
configure of other modules into this file later.
Check that if we are doing sub-configure from MPICH, simply use the main
embedded hwloc rather than build another one.
There are compilation warnings that come up because this flag is
enabled. Specifically, we see this:
MOD src/binding/fortran/use_mpi/mpi.mod-stamp
src/mpi/comm/commutil.c: In function ‘MPII_compare_info_hint’:
src/mpi/comm/commutil.c:1139:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
1139 | int MPII_compare_info_hint(const char *hint_str, MPIR_Comm * comm_ptr, int *info_args_are_equal)
| ^~~~~~~~~~~~~~~~~~~~~~
src/mpi/comm/commutil.c:1139:5: note: variable tracking size limit exceeded
However, this warning doesn't provide any useful information and can be
ignored, so disable it.
Strict compiler builds need to have some flags that are specific to
certain compilers (e.g., -Wno-unused-label). This copies (and slightly
modifies) the compiler check from the fortran configuration.