disallow usage of qeq fixes with incompatible GPU and USER-INTEL packages
This commit is contained in:
@ -24,6 +24,8 @@
|
||||
#include "force.h"
|
||||
#include "memory.h"
|
||||
#include "neigh_list.h"
|
||||
#include "pair.h"
|
||||
#include "suffix.h"
|
||||
#include "text_file_reader.h"
|
||||
#include "update.h"
|
||||
|
||||
@ -300,6 +302,12 @@ void FixQEq::setup_pre_force(int vflag)
|
||||
if (force->newton_pair == 0)
|
||||
error->all(FLERR,"QEQ with 'newton pair off' not supported");
|
||||
|
||||
if (force->pair) {
|
||||
if (force->pair->suffix_flag & (Suffix::INTEL|Suffix::GPU))
|
||||
error->all(FLERR,"QEQ is not compatiple with suffix version "
|
||||
"of pair style");
|
||||
}
|
||||
|
||||
deallocate_storage();
|
||||
allocate_storage();
|
||||
|
||||
|
||||
@ -28,6 +28,8 @@ class Pair : protected Pointers {
|
||||
friend class FixGPU;
|
||||
friend class FixIntel;
|
||||
friend class FixOMP;
|
||||
friend class FixQEq;
|
||||
friend class PairHybrid;
|
||||
friend class ThrOMP;
|
||||
friend class Info;
|
||||
|
||||
|
||||
@ -948,9 +948,7 @@ void PairHybrid::modify_special(int m, int /*narg*/, char **arg)
|
||||
special[2] = utils::numeric(FLERR,arg[2],false,lmp);
|
||||
special[3] = utils::numeric(FLERR,arg[3],false,lmp);
|
||||
|
||||
// have to cast to PairHybrid to work around C++ access restriction
|
||||
|
||||
if (((PairHybrid *)styles[m])->suffix_flag & (Suffix::INTEL|Suffix::GPU))
|
||||
if (styles[m]->suffix_flag & (Suffix::INTEL|Suffix::GPU))
|
||||
error->all(FLERR,"Pair_modify special is not compatible with "
|
||||
"suffix version of hybrid substyle");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user