Compilation error on Fujitsu A64FX (VASP 6.3.0)

Questions regarding the compilation of VASP on various platforms: hardware, compilers and libraries, etc.


Moderators: Global Moderator, Moderator

Post Reply
Message
Author
shiba_itcut
Newbie
Newbie
Posts: 3
Joined: Thu Jan 27, 2022 5:55 am

Compilation error on Fujitsu A64FX (VASP 6.3.0)

#1 Post by shiba_itcut » Wed Apr 06, 2022 12:58 am

Hello,

I am trying to install VASP 6.3.0 on Fujitsu A64FX processor
using Fujitsu Compiler (Fujitsu Dev. Studio 1.2.35 + Fujitsu MPI 1.2.35).
I have the following error during the compilation.
Your help would be highly appreciated.

Error message

Code: Select all

...
...
...
mpifrt -Kopenmp,simd_nouse_multiple_structures -X03  -Koptmsg=2 -Kfast -I(PATH_TO_MY_FFTW)  -c ml_interface.f90
Fortran diagnostic messages: program name(ml_interface)
 Module subprogram name(MACHINE_LEARNING_READER)
  jwd1716i-s  "ml_interface.f90", line 273, column 20: 'READ_TAG_REAL' already used as an internal subroutine name.
  jwd1716i-s  "ml_interface.f90", line 274, column 20: 'READ_TAG_INTEGER' already used as an internal subroutine name.
  jwd1716i-s  "ml_interface.f90", line 275, column 20: 'READ_TAG_LOGICAL' already used as an internal subroutine name.
  jwd1716i-s  "ml_interface.f90", line 279, column 20: 'READ_TAG_ARRAY_REAL' already used as an internal subroutine name.
  jwd1716i-s  "ml_interface.f90", line 280, column 20: 'READ_TAG_ARRAY_INTEGER' already used as an internal subroutine name.
  jwd2516i-s  "ml_interface.f90", line 330, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
  jwd2516i-s  "ml_interface.f90", line 334, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
  jwd2516i-s  "ml_interface.f90", line 337, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
  jwd2516i-s  "ml_interface.f90", line 340, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
  jwd2516i-s  "ml_interface.f90", line 343, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
  jwd2516i-s  "ml_interface.f90", line 346, column 15: Reference to 'READ_TAG' not consistent with any specific interface of the generic interface.
...
...
...
makefile.include
(virtually no change from "makefile.include.fujitsu_a64fx_omp")

Code: Select all

# Default precompiler options
CPP_OPTIONS = -DHOST=\"FJ-A64FX\" \
              -DMPI -DMPI_BLOCK=8000 -Duse_collective \
              -DscaLAPACK \
              -DCACHE_SIZE=4000 \
              -Davoidalloc \
              -Dvasp6 \
              -Duse_bse_te \
              -Dtbdyn \
              -Dfock_dblbuf \
              -D_OPENMP

CPP         = cpp -P -traditional-cpp $(CPP_OPTIONS) $*$(FUFFIX) > $*$(SUFFIX)

# N.B.: to cross-compile for A64FX on X86_64 replace mpifrt, frt, fcc, and FCC
#       by mpifrtpx, frtpx, fccpx, and FCCpx, respectively.
FC          = mpifrt -Kopenmp,simd_nouse_multiple_structures -X03
FCL         = mpifrt -Kopenmp,simd_nouse_multiple_structures

FREE        =

FFLAGS      = -Koptmsg=2
OFLAG       = -Kfast
OFLAG_IN    = $(OFLAG)
DEBUG       = -O0 -g
OFLAG_1     = -O1
OFLAG_2     = -O2
OFLAG_3     = -Kfast

OBJECTS     = zdotc.o fftmpiw.o fftmpi_map.o fft3dlib.o fftw3d.o
OBJECTS_O1 += minimax_dependence.o fftw3d.o fftmpi.o fftmpiw.o
OBJECTS_O2 += fft3dlib.o

# For what used to be vasp.5.lib
CPP_LIB     = $(CPP)
FC_LIB      = frt  -Ksimd_nouse_multiple_structures
CC_LIB      = fcc -Nclang
CFLAGS_LIB  = -O3
FFLAGS_LIB  = $(OFLAG)
FREE_LIB    = $(FREE)

OBJECTS_LIB = linpack_double.o

# For the parser library
CXX_PARS    = FCC -Nclang
LLIBS       = -lstdc++
##
## Customize as of this point! Of course you may change the preceding
## part of this file as well if you like, but it should rarely be
## necessary ...
##

# BLAS, LAPACK, and SCALAPACK (mandatory)
LLIBS      += -SSL2BLAMP -SCALAPACK

# HINT: Fujitsu maintains its own fftw fork on GitHub
#       (https://github.com/fujitsu/fftw3)
FFTW       ?= (PATH_OF_MY_FFTW3)
LLIBS      += -L$(FFTW)/lib -lfftw3 -lfftw3_omp
INCS        = -I$(FFTW)/include

# HDF5-support (optional but strongly recommended)
#CPP_OPTIONS+= -DVASP_HDF5
#HDF5_ROOT  ?= /path/to/your/hdf5/installation
#LLIBS      += -L$(HDF5_ROOT)/lib -lhdf5_fortran
#INCS       += -I$(HDF5_ROOT)/include

# For the VASP-2-Wannier90 interface (optional)
#CPP_OPTIONS    += -DVASP2WANNIER90
#WANNIER90_ROOT ?= /path/to/your/wannier90/installation
#LLIBS          += -L$(WANNIER90_ROOT)/lib -lwannier
Best regards,
Hayato Shiba
Information Technology Center, The University of Tokyo, Japan

andreas.singraber
Global Moderator
Global Moderator
Posts: 236
Joined: Mon Apr 26, 2021 7:40 am

Re: Compilation error on Fujitsu A64FX (VASP 6.3.0)

#2 Post by andreas.singraber » Wed Apr 06, 2022 11:49 am

Hello Hayato Shiba,

unfortunately there is a known issue with the Fujitsu compiler together with VASP 6.3.0 which leads to the build error you observed. The upcoming version 6.3.1 already includes a fix for this. In the meantime you could try the workaround described in the Wiki's Known Issues page. This should allow you to compile a working executable for VASP which lacks machine learning capabilities (ML_LMLFF = .TRUE. causes an error) but should otherwise work fine.

All the best,

Andreas Singraber

shiba_itcut
Newbie
Newbie
Posts: 3
Joined: Thu Jan 27, 2022 5:55 am

Re: Compilation error on Fujitsu A64FX (VASP 6.3.0)

#3 Post by shiba_itcut » Fri Apr 08, 2022 12:53 pm

Hello Andreas,

Thank you very much for you reply, I highly appreciate your help. I did actually maange to compile VASP 6.3.0 by Fujitsu Compiler 1.2.35 with the workaround you indicated.

In addition to "ml_interface.F", I also encountered error messages when compiling
src/ml_ff_math.F
and
src/vhdf5_base.F
with Fujitsu compiler (1.2.35), which I believe you can find easily if you have the access to Fujitsu A64FX machines. I could get through the both by minor modification of these codes, but I hope you could check them before you make the update to VASP version 6.3.1.

Best,
Hayato

andreas.singraber
Global Moderator
Global Moderator
Posts: 236
Joined: Mon Apr 26, 2021 7:40 am

Re: Compilation error on Fujitsu A64FX (VASP 6.3.0)

#4 Post by andreas.singraber » Fri Apr 08, 2022 3:04 pm

Hello Hayato!

Thanks a lot for your feedback, I'm glad you could compile VASP with these changes!

We don't have access (yet) to the Fujitsu compiler and hardware, so we had to fix some issues for 6.3.0 given only the reports of a person who had access. Unfortunately, some problems slipped through and didn't make it into the 6.3.0 release. This is why we had to list this workaround on the known issues page.

However, we were not reported the other two issues you mentioned in ml_ff_math.F and vhdf5_base.F (maybe a different compiler version was used). It would be really helpful if you could post the compiler error messages and/or the changes you had to apply in order to compile VASP correctly. Then we could include also these fixes in the 6.3.1 version. Thank you!!

We are in the process of organizing a Fujitsu machine+compiler so we can tightly integrate the A64FX architecture in our regular testing process, so I hope there will less problems in the future.

All the best,

Andreas Singraber

shiba_itcut
Newbie
Newbie
Posts: 3
Joined: Thu Jan 27, 2022 5:55 am

Re: Compilation error on Fujitsu A64FX (VASP 6.3.0)

#5 Post by shiba_itcut » Sat Apr 09, 2022 1:38 pm

Hello Andreas,

regarding "vhdf5_base.F", I have the following error:

Code: Select all

mpifrt -Kopenmp,simd_nouse_multiple_structures -X03  -Koptmsg=2 -Kfast -I(path_to_fftw) -I(path_to_hdf5)  -c vhdf5_base.f90
Fortran diagnostic messages: program name(vhdf5_base)
 Module subprogram name(vh5_write_double_complex_array_nd)
  jwd2043i-s  "vhdf5_base.f90", line 1428: Value must be assigned for INTENT(OUT) variable 'dimensions'.
 Module subprogram name(vh5_write_complex_array_nd)
  jwd2043i-s  "vhdf5_base.f90", line 1675: Value must be assigned for INTENT(OUT) variable 'dimensions'.
I am commenting out functions "vh5_write_double_complex_array_nd" and "vh5_write_complex_array_nd" to avoid these errors.

For "ml_ff_math.F", L4685 & L4689 (before converting to f90) seem to be too long, which can be easily fixed with dividing
them into continuation lines.

Code: Select all

 mpifrt -Kopenmp,simd_nouse_multiple_structures -X03  -Koptmsg=2 -Kfast -I(path_to_fftw) -I(path_to_hdf5)  -c ml_ff_math.f90
        ..........
  Internal subprogram name(CALCULATE_INVERSE_OF_COVARIANCE_MATRIX)
  jwd1048i-i  "ml_ff_math.f90", line 4502: Length of source record exceeds 255 characters.
  jwd1497i-s  "ml_ff_math.f90", line 4502, column 254: 'SC' not a component of a derived type, cannot be specified as structure component.
  jwd1048i-i  "ml_ff_math.f90", line 4506: Length of source record exceeds 255 characters.
  jwd1497i-s  "ml_ff_math.f90", line 4506, column 254: 'SC' not a component of a derived type, cannot be specified as structure component
.

Best,
Hayato

andreas.singraber
Global Moderator
Global Moderator
Posts: 236
Joined: Mon Apr 26, 2021 7:40 am

Re: Compilation error on Fujitsu A64FX (VASP 6.3.0)

#6 Post by andreas.singraber » Sat Apr 09, 2022 8:23 pm

Hello Hayato!

Great, thanks a lot for the effort and reproducing the errors!! We'll fix this in VASP 6.3.1.

All the best,

Andreas

Post Reply