Open
Description
Debian unstable currently has libint2-2.7.2. I built 2.9.0 with the same configure option, then installed the shared library and ran the cp2k (which was built against 2.7.2 or earlier) testsuite, which segfaults in the libint wrapper:
HFX_MEM_INFO| Est. max. program size before HFX [MiB]: 164
Thread 1 "cp2k" received signal SIGSEGV, Segmentation fault.
0x0000555556ac7c5b in hfx_libint_interface::evaluate_eri_screen (libint=..., a=..., b=..., c=..., d=..., zeta_a=4.3362376435999996, zeta_b=4.3362376435999996, zeta_c=4.3362376435999996,
zeta_d=4.3362376435999996, n_a=0, n_b=1, n_c=0, n_d=1, max_val=0, potential_parameter=..., r1=1.3379568968392406, r2=1.3379568968392406, p_work=<not associated>)
at /build/reproducible-path/cp2k-2023.2/src/hfx_libint_interface.F:1359
1359 max_val = MAX(max_val, ABS(p_work(i)))
(gdb) l
1354 CALL build_quartet_data_screen(B, A, D, C, Zeta_B, Zeta_A, Zeta_D, Zeta_C, m_max, &
1355 potential_parameter, libint, R1, R2)
1356
1357 CALL cp_libint_get_eris(n_c, n_d, n_a, n_b, libint, p_work, a_mysize)
1358 DO i = 1, mysize
1359 max_val = MAX(max_val, ABS(p_work(i)))
1360 END DO
1361 CASE (5)
1362 CALL build_quartet_data_screen(C, D, A, B, Zeta_C, Zeta_D, Zeta_A, Zeta_B, m_max, &
1363 potential_parameter, libint, R1, R2)
(gdb) bt
#0 0x0000555556ac7c5b in hfx_libint_interface::evaluate_eri_screen (libint=..., a=..., b=..., c=..., d=..., zeta_a=4.3362376435999996, zeta_b=4.3362376435999996, zeta_c=4.3362376435999996,
zeta_d=4.3362376435999996, n_a=0, n_b=1, n_c=0, n_d=1, max_val=0, potential_parameter=..., r1=1.3379568968392406, r2=1.3379568968392406, p_work=<not associated>)
at /build/reproducible-path/cp2k-2023.2/src/hfx_libint_interface.F:1359
#1 0x0000555556a99562 in hfx_screening_methods::calc_screening_functions (qs_env=<optimized out>, basis_parameter=..., lib=..., potential_parameter=..., coeffs_set=<not associated>,
coeffs_kind=<not associated>, coeffs_pgf=..., radii_pgf=..., max_set=3, max_pgf=3, n_threads=1, i_thread=0, p_work=<not associated>) at /build/reproducible-path/cp2k-2023.2/src/hfx_screening_methods.F:424
#2 0x00005555560483d8 in integrate_four_center::__hfx_energy_potential_MOD_integrate_four_center._omp_fn.0 () at /build/reproducible-path/cp2k-2023.2/src/hfx_energy_potential.F:825
#3 0x00007ffff3b26866 in GOMP_parallel (fn=fn@entry=0x55555603a390 <integrate_four_center::__hfx_energy_potential_MOD_integrate_four_center._omp_fn.0>, data=data@entry=0x7fffffffac30, num_threads=1,
num_threads@entry=0, flags=flags@entry=0) at ../../../src/libgomp/parallel.c:178
#4 0x000055555604b3b7 in hfx_energy_potential::integrate_four_center (qs_env=0x55555d1b26b0, x_data=<error reading variable: value requires 1073152 bytes, which is more than max-value-size>, ks_matrix=...,
ehfx=0, rho_ao=..., hfx_section=0x55555d221f60, para_env=0x55555d3813d0, geometry_did_change=.TRUE., irep=1, distribute_fock_matrix=.TRUE., ispin=1)
at /build/reproducible-path/cp2k-2023.2/src/hfx_energy_potential.F:407
#5 0x0000555556ae0aaa in hfx_exx::calculate_exx (qs_env=0x55555d1b26b0, unit_nr=6, hfx_sections=0x55555d221f60,
x_data=<error reading variable: value requires 1073152 bytes, which is more than max-value-size>, do_gw=.FALSE., do_admm=.FALSE., calc_forces=.FALSE., reuse_hfx=.FALSE., do_im_time=.FALSE.,
e_ex_from_gw=4.6355780447858831e-310, e_admm_from_gw=..., t3=0) at /build/reproducible-path/cp2k-2023.2/src/hfx_exx.F:229
#6 0x00005555569795b3 in mp2::mp2_main (qs_env=0x55555d1b26b0, calc_forces=.FALSE.) at /build/reproducible-path/cp2k-2023.2/src/mp2.F:743
#7 0x0000555556851d81 in qs_energy::qs_energies_mp2 (calc_forces=.FALSE., qs_env=0x55555d1b26b0) at /build/reproducible-path/cp2k-2023.2/src/qs_energy.F:170
#8 qs_energy::qs_energies (qs_env=0x55555d1b26b0, consistent_energies=<optimized out>, calc_forces=.FALSE.) at /build/reproducible-path/cp2k-2023.2/src/qs_energy.F:121
#9 0x0000555556842d1c in qs_force::qs_calc_energy_force (qs_env=<optimized out>, calc_force=.FALSE., consistent_energies=.FALSE., linres=.FALSE.) at /build/reproducible-path/cp2k-2023.2/src/qs_force.F:112
#10 0x00005555560d623a in force_env_methods::force_env_calc_energy_force (force_env=0x55555d420e00, calc_force=.FALSE., consistent_energies=<error reading variable: Cannot access memory at address 0x0>,
skip_external_control=<error reading variable: Cannot access memory at address 0x0>, eval_energy_forces=<error reading variable: Cannot access memory at address 0x0>,
require_consistent_energy_force=<error reading variable: Cannot access memory at address 0x0>, linres=<error reading variable: Cannot access memory at address 0x0>,
calc_stress_tensor=<error reading variable: Cannot access memory at address 0x0>) at /build/reproducible-path/cp2k-2023.2/src/force_env_methods.F:256
#11 0x000055555558f027 in cp2k_runs::cp2k_run (input_declaration=0x555558ea5e80, input_file_name=..., output_unit=6, mpi_comm=..., initial_variables=..., _input_file_name=_input_file_name@entry=1024,
_initial_variables=1024, _initial_variables=1024) at /build/reproducible-path/cp2k-2023.2/src/start/cp2k_runs.F:355
#12 0x0000555555591a79 in cp2k_runs::run_input (input_declaration=0x555558ea5e80, input_file_path=..., output_file_path=..., initial_variables=...,
mpi_comm=<error reading variable: Cannot access memory at address 0x0>, _input_file_path=_input_file_path@entry=1024, _output_file_path=1024, _initial_variables=1024)
at /build/reproducible-path/cp2k-2023.2/src/start/cp2k_runs.F:997
#13 0x000055555557db16 in cp2k () at /build/reproducible-path/cp2k-2023.2/src/start/cp2k.F:379
(gdb)
Looks like the API or ABI changed between 2.7.2 and 2.9.0 but the SOVERSION
stayed at 2?
AFAICT, p_work
is not associated after the call to libint2_build_eri
, when I step into it I see this function being called:
332 CALL C_F_PROCPOINTER(libint2_build_eri(n_d, n_c, n_b, n_a), pbuild)
(gdb)
333 CALL pbuild(lib%prv)
(gdb)
Download failed: Invalid argument. Continuing without source file ./obj-x86_64-linux-gnu/./sourcedir/src/_aB_P__0__P__1___TwoPRep_S__0__S__1___Ab__up_0.cc.
_aB_P__0__P__1___TwoPRep_S__0__S__1___Ab__up_0 (inteval=0x7ffffffd1540) at ./sourcedir/src/_aB_P__0__P__1___TwoPRep_S__0__S__1___Ab__up_0.cc:31
Metadata
Assignees
Labels
No labels
Activity