small tweaks from static code analysis
This commit is contained in:
@ -54,7 +54,7 @@ int PPPMT::bytes_per_atom() const {
|
||||
}
|
||||
|
||||
template <class numtyp, class acctyp, class grdtyp, class grdtyp4>
|
||||
grdtyp * PPPMT::init(const int nlocal, const int nall, FILE *_screen,
|
||||
grdtyp *PPPMT::init(const int nlocal, const int nall, FILE *_screen,
|
||||
const int order, const int nxlo_out,
|
||||
const int nylo_out, const int nzlo_out,
|
||||
const int nxhi_out, const int nyhi_out,
|
||||
@ -69,14 +69,14 @@ grdtyp * PPPMT::init(const int nlocal, const int nall, FILE *_screen,
|
||||
|
||||
flag=device->init(*ans,nlocal,nall);
|
||||
if (flag!=0)
|
||||
return 0;
|
||||
return nullptr;
|
||||
if (sizeof(grdtyp)==sizeof(double) && device->double_precision()==false) {
|
||||
flag=-15;
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
if (device->ptx_arch()>0.0 && device->ptx_arch()<1.1) {
|
||||
flag=-4;
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
ucl_device=device->gpu;
|
||||
|
||||
Reference in New Issue
Block a user