Refine GPU runtime controls and input checker
This commit is contained in:
@@ -318,6 +318,16 @@ void fill_bssn_em_matter_cuda_views(Block *cg, double **matter,
|
||||
|
||||
bool bssn_em_cuda_use_resident_sync(int lev)
|
||||
{
|
||||
static int enabled = -1;
|
||||
if (enabled < 0)
|
||||
{
|
||||
const char *env = getenv("AMSS_CUDA_RESIDENT_SYNC");
|
||||
if (!env)
|
||||
env = getenv("AMSS_CUDA_EM_RESIDENT_SYNC");
|
||||
enabled = env ? ((atoi(env) != 0) ? 1 : 0) : 1;
|
||||
}
|
||||
if (!enabled)
|
||||
return false;
|
||||
#ifdef WithShell
|
||||
(void)lev;
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user