-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calling 4c1e integrals - segfault/double free #91
Comments
I also had this error. My guess is that it seems like the cache_size variable value in the CINT4c1e_drv() function of cint4c1e.c should be bigger. This value is defined as Lines 282 to 283 in 7086956
Changing this definition (as well as L273) to
seems to resolve the segfault for me, at least for the test cases obtained by adding the following lines
somewhere around line 148 (just before the first test function) of the file test_cint4c1e.py in the test directory libcint/testsuite. The segfault did not appear in my test cases for basis sets sto-3g, cc-pvdz, aug-cc-pvdz, aug-cc-pvtz. Furthermore, I believe in PySCF 2.3.0 the molecular integral |
Originally posted by @duykhoidang in #89 (comment)
I am trying to call cint4c1e using
cint4c1e_sph(buf, shls, atm, natm, bas, nbas, env)
andcint4c1e_sph(buf, shls, atm, natm, bas, nbas, env, NULL)
, but both versions of this call result in a segfault or double-free error. Replacingcint4c1e_sph
withcint2e_sph
results in working code with no segfault and the correct 2e-integrals, so I do not believe the loop structure or setup of thebuf
,shls
,atm
,natm
,bas
,nbas
,env
variables are causing the issue. It seems like the 4c1e overlap integral code is possibly writing memory out of bounds. Do you have this error?The text was updated successfully, but these errors were encountered: