And I don’t know fortran, so I have no opinion of my own.
The first step is to reproduce on our end....
Indeed. I have just released Asap 3.11.3 with support for OpenKIM v. 2.0.0.beta3. I’ll announce it once I have updated the web pages. You should be able to install it and build it with the Intel compilers by following the instructions here:
https://wiki.fysik.dtu.dk/asap/Installation#optimized-installation
Remember to install ASE first:
python3 -m pip install ase --user
OK, I have been able to test this on two different systems: one with v16.0 and one with v18.0 of the Intel compilers
With the 16.0 compilers there are no segfaults.
With the 18.0 compilers the OpenKIM_AllModels.py (with no blacklist) segfaults in this way:
(gdb) run OpenKIM_AllModels.py
Starting program: /panfs/roc/groups/9/elliotrs/relliott/miniconda3/bin/python OpenKIM_AllModels.py
[Thread debugging using libthread_db enabled]
Missing separate debuginfo for /panfs/roc/groups/9/elliotrs/relliott/miniconda3/lib/python3.7/site-packages/numpy/core/../.libs/libgfortran-ed201abd.so.3.0.0
[New Thread 0x7fffe9dcc700 (LWP 10551)]
[New Thread 0x7fffe93cb700 (LWP 10552)]
[New Thread 0x7fffe69ca700 (LWP 10553)]
[New Thread 0x7fffe3fc9700 (LWP 10554)]
[New Thread 0x7fffe15c8700 (LWP 10555)]
[New Thread 0x7fffdebc7700 (LWP 10556)]
[New Thread 0x7fffdc1c6700 (LWP 10557)]
[Thread 0x7fffe15c8700 (LWP 10555) exited]
[Thread 0x7fffdc1c6700 (LWP 10557) exited]
[Thread 0x7fffe9dcc700 (LWP 10551) exited]
[Thread 0x7fffe69ca700 (LWP 10553) exited]
[Thread 0x7fffe93cb700 (LWP 10552) exited]
[Thread 0x7fffe3fc9700 (LWP 10554) exited]
[Thread 0x7fffdebc7700 (LWP 10556) exited]
Detaching after fork from child process 10561.
Detaching after fork from child process 10562.
Detaching after fork from child process 10563.
KIM model: EAM_Magnetic2GQuintic_ChiesaDerletDudarev_2011_Fe__MO_140444321607_002
Potential info: with 5th order knot functions
Supported elements: ['Fe']
Generated a bcc system with 686 Fe-atoms and 0 None-atoms
Lattice constant a = 2.87
Program received signal SIGSEGV, Segmentation fault.
__libc_free (mem=0x61) at malloc.c:3716
3716 if (chunk_is_mmapped(p)) /* release mmapped memory. */
(gdb) bt
#0 __libc_free (mem=0x61) at malloc.c:3716
#1 0x00007fffecec3f2c in for_deallocate () from /panfs/roc/intel/x86_64/2018/parallel_studio_xe_msi/compilers_and_libraries_2018.0.128/linux/compiler/lib/intel64/libifcoremt.so.5
#2 0x00007fffee0d3dd4 in kim_model_compute_arguments_module_mp_kim_model_compute_arguments_get_neighbor_list_ () from /home/elliotrs/relliott/kim-api/build/test-install/lib64/libkim-api-v2.so.2
#3 0x00007fffe9bc6f6f in compute_energy_forces () from /home/elliotrs/relliott/kim-api/build/test-install/lib64/kim-api-v2/model-drivers/EAM_Magnetic2GQuintic__MD_543355979582_002/libkim-api-v2-model-driver.so
#4 0x00007fffee124cc4 in KIM::ModelImplementation::ModelCompute(KIM::ComputeArguments const*) const () from /home/elliotrs/relliott/kim-api/build/test-install/lib64/libkim-api-v2.so.2
#5 0x00007fffee124664 in KIM::ModelImplementation::Compute(KIM::ComputeArguments const*) const () from /home/elliotrs/relliott/kim-api/build/test-install/lib64/libkim-api-v2.so.2
#6 0x00007fffefac79ef in AsapNS::OpenKIMcalculator::DoCalculate (this=0x61) at OpenKIMimport/OpenKIMcalculator.cpp:630
#7 0x00007fffefac77bf in AsapNS::OpenKIMcalculator::Calculate (this=0x61, pyatoms=0x40000) at OpenKIMimport/OpenKIMcalculator.cpp:598
#8 0x00007fffefac4390 in AsapNS::OpenKIMcalculator::GetPotentialEnergy (this=0x61, pyatoms=0x40000) at OpenKIMimport/OpenKIMcalculator.cpp:311
#9 0x00007fffefab7f47 in PyAsap_PotentialGetPotentialEnergy (self=0x61, args=0x40000, kwargs=0x7fffffffb600) at Interface/PotentialInterface.cpp:720
#10 0x00005555556b7ea4 in _PyMethodDef_RawFastCallKeywords ()
#11 0x00005555556c0bef in _PyMethodDescr_FastCallKeywords ()
#12 0x000055555572cc68 in _PyEval_EvalFrameDefault ()
#13 0x0000555555666528 in _PyEval_EvalCodeWithName ()
#14 0x00005555556b7645 in _PyFunction_FastCallKeywords ()
#15 0x00005555557285b0 in _PyEval_EvalFrameDefault ()
#16 0x0000555555666528 in _PyEval_EvalCodeWithName ()
#17 0x00005555556673a4 in PyEval_EvalCodeEx ()
#18 0x00005555556673cc in PyEval_EvalCode ()
#19 0x0000555555781304 in run_mod ()
#20 0x0000555555789611 in PyRun_FileExFlags ()
#21 0x0000555555789804 in PyRun_SimpleFileExFlags ()
#22 0x000055555578b17d in pymain_main.constprop.327 ()
#23 0x000055555578b3f0 in _Py_UnixMain ()
#24 0x00007ffff7648d20 in __libc_start_main (main=0x555555646e20 <main>, argc=2, ubp_av=0x7fffffffc5e8, init=<value optimized out>, fini=<value optimized out>, rtld_fini=<value optimized out>, stack_end=0x7fffffffc5d8) at libc-start.c:226
#25 0x0000555555737e32 in _start ()
This look, to me, different than the backtrace Jakob presented.
I've also found that this same segfault occurs with the fortran example models and the example simulators. SO, it is not an ase or asap thing. Not sure why Jakob is not seeing similar problems with other models...
So it seems to be isolated to the v18.0 Intel compilers.
The backtrace indicates a fortran deallocate but there is no such deallocate in the code anywhere in the indicated functions. So, I would guess that the deallocation is some sort of internal fortran behavior.
So, it seems (to me, at the moment) to be a ifort compiler bug....
Ryan