Skip to content

Commit

Permalink
remove global nao_pair
Browse files Browse the repository at this point in the history
  • Loading branch information
cjknight committed Aug 6, 2024
1 parent 2b91767 commit 90edb2f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 0 additions & 1 deletion gpu/src/device.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ public :

int blksize;
int nset;
int nao_pair;

int size_fdrv;
int size_buf_vj;
Expand Down
4 changes: 3 additions & 1 deletion gpu/src/device_cuda.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ void Device::init_get_jk(py::array_t<double> _eri1, py::array_t<double> _dmtril,
blksize = _blksize;
nset = _nset;

nao_pair = nao * (nao+1) / 2;
int nao_pair = nao * (nao+1) / 2;

int _size_vj = nset * nao_pair;
if(_size_vj > dd->size_vj) {
Expand Down Expand Up @@ -508,6 +508,8 @@ void Device::pull_get_jk(py::array_t<double> _vj, py::array_t<double> _vk, int n

double * vj = static_cast<double*>(info_vj.ptr);

int nao_pair = nao * (nao+1) / 2;

int size = nset * nao_pair * sizeof(double);

double * tmp;
Expand Down

0 comments on commit 90edb2f

Please sign in to comment.