accfft: fix narrowing error. (#13909)

This commit is contained in:
t-karatsu 2019-11-28 01:15:22 +09:00 committed by Adam J. Stewart
parent f07131a390
commit 515f1466c8
2 changed files with 14 additions and 0 deletions

View file

@ -0,0 +1,11 @@
--- spack-src/include/parUtils.txx.org 2019-11-27 16:41:07.438799437 +0900
+++ spack-src/include/parUtils.txx 2019-11-27 16:54:51.654921619 +0900
@@ -70,7 +70,7 @@
}
omp_par::scan(&s_cnt[0],&s_dsp[0],np+1);
- size_t range[2]={0,np};
+ size_t range[2]={0,(unsigned long)np};
for(size_t np_new=np; np_new>1; np_new/=kway){
double tt=omp_get_wtime();
if(kway>np_new) kway=np_new;

View file

@ -24,6 +24,9 @@ class Accfft(CMakePackage, CudaPackage):
depends_on('parallel-netcdf', when='+pnetcdf')
# fix error [-Wc++11-narrowing]
patch('fix_narrowing_error.patch')
parallel = False
def cmake_args(self):