mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2024-08-16 18:38:28 +02:00
Fixed dgemm bug
This commit is contained in:
parent
bcdbc49d5f
commit
511eba5843
@ -5432,18 +5432,19 @@ qmckl_exit_code qmckl_compute_tmp_c_hpc (
|
||||
const int64_t LDB = elec_num;
|
||||
const int64_t LDC = elec_num;
|
||||
|
||||
const int64_t af = elec_num*elec_num;
|
||||
const int64_t bf = elec_num*nucl_num*(cord_num+1);
|
||||
const int64_t cf = bf;
|
||||
|
||||
for (int64_t nw=0; nw < walk_num; ++nw) {
|
||||
for (int64_t i=0; i<cord_num; ++i){
|
||||
info = qmckl_dgemm(context, TransA, TransB, M, N, K, alpha, \
|
||||
// &een_rescaled_e[0+0*elec_num+i*elec_num*elec_num+nw*elec_num*elec_num*(cord_num+1)],
|
||||
&(een_rescaled_e[ i*elec_num*elec_num+nw*elec_num*elec_num*(cord_num+1)]), \
|
||||
&(een_rescaled_e[af*(i+nw*(cord_num+1))]), \
|
||||
LDA, \
|
||||
// &een_rescaled_n[0+0*elec_num+0*elec_num*nucl_num+nw*elec_num*nucl_num*(cord_num+1)],
|
||||
&(een_rescaled_n[ nw*elec_num*nucl_num*(cord_num+1)]), \
|
||||
&(een_rescaled_n[bf*nw]), \
|
||||
LDB, \
|
||||
beta, \
|
||||
// &tmp_c[0+0*elec_num+0*elec_num*nucl_num+i*elec_num*nucl_num*(cord_num+1)+nw*elec_num*nucl_num*(cord_num+1)*cord_num],
|
||||
&(tmp_c[ i*elec_num*nucl_num*(cord_num+1)+nw*elec_num*nucl_num*(cord_num+1)*cord_num]), \
|
||||
&(tmp_c[cf*(i+nw*cord_num)]), \
|
||||
LDC);
|
||||
}
|
||||
}
|
||||
@ -5677,18 +5678,19 @@ qmckl_exit_code qmckl_compute_dtmp_c_hpc (const qmckl_context context,
|
||||
const int64_t LDB = elec_num;
|
||||
const int64_t LDC = 4*elec_num;
|
||||
|
||||
const int64_t af = elec_num*elec_num*4;
|
||||
const int64_t bf = elec_num*nucl_num*(cord_num+1);
|
||||
const int64_t cf = elec_num*4*nucl_num*(cord_num+1);
|
||||
|
||||
for (int64_t nw=0; nw < walk_num; ++nw) {
|
||||
for (int64_t i=0; nw < cord_num; ++i) {
|
||||
for (int64_t i=0; i < cord_num; ++i) {
|
||||
info = qmckl_dgemm(context, TransA, TransB, M, N, K, alpha, \
|
||||
//&een_rescaled_e_deriv_e[0+0*elec_num+0*elec_num*4+i*elec_num*4*elec_num+nw*elec_num*4*elec_num*(cord_num+1)],
|
||||
&(een_rescaled_e_deriv_e[i*elec_num*4*elec_num+nw*elec_num*4*elec_num*(cord_num+1)]), \
|
||||
&(een_rescaled_e_deriv_e[af*(i+nw*(cord_num+1))]), \
|
||||
LDA, \
|
||||
//&een_rescaled_n[0+0*elec_num+0*elec_num*nucl_num+nw*elec_num*nucl_num*(cord_num+1)],
|
||||
&(een_rescaled_n[nw*elec_num*nucl_num*(cord_num+1)]), \
|
||||
&(een_rescaled_n[bf*nw]), \
|
||||
LDB, \
|
||||
beta, \
|
||||
//&dtmp_c[0+0*elec_num+0*elec_num*4+0*elec_num*4*nucl_num+i*elec_num*4*nucl_num*(cord_num+1)+nw*elec_num*4*nucl_num*(cord_num+1)*cord_num],
|
||||
&(dtmp_c[i*elec_num*4*nucl_num*(cord_num+1)+nw*elec_num*4*nucl_num*(cord_num+1)*cord_num]), \
|
||||
&(dtmp_c[cf*(i+nw*cord_num)]), \
|
||||
LDC);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user