diff --git a/python/lammps/core.py b/python/lammps/core.py index 01a3cce842..7349e877c6 100644 --- a/python/lammps/core.py +++ b/python/lammps/core.py @@ -1452,7 +1452,7 @@ class lammps(object): for p in [b'GPU', b'KOKKOS', b'USER-INTEL', b'USER-OMP']: c = b'api' result[p.decode()] = {} - for s in [b'cuda', b'hip', b'pthreads', b'opencl', b'openmp']: + for s in [b'cuda', b'hip', b'pthreads', b'opencl', b'openmp', b'serial']: if self.lib.lammps_config_accelerator(p,c,s): result[p.decode()][c.decode()] = s.decode() c = b'precision' diff --git a/src/info.cpp b/src/info.cpp index f9394a1433..27975a73c4 100644 --- a/src/info.cpp +++ b/src/info.cpp @@ -1208,7 +1208,7 @@ bool Info::has_accelerator_feature(const std::string &package, } #endif #if defined(LMP_USER_OMP) - if (package == "OPENMP") { + if (package == "USER-OMP") { if (category == "precision") { if (setting == "double") return true; else return false; @@ -1216,14 +1216,15 @@ bool Info::has_accelerator_feature(const std::string &package, if (category == "api") { #if defined(_OPENMP) if (setting == "openmp") return true; - else return false; +#else + if (setting == "serial") return true; #endif return false; } } #endif #if defined(LMP_USER_INTEL) - if (package == "INTEL") { + if (package == "USER-INTEL") { if (category == "precision") { if (setting == "double") return true; else if (setting == "mixed") return true; @@ -1231,8 +1232,12 @@ bool Info::has_accelerator_feature(const std::string &package, else return false; } if (category == "api") { +#if defined(_OPENMP) if (setting == "openmp") return true; - else return false; +#else + if (setting == "serial") return true; +#endif + return false; } } #endif