diff options
author | 2020-07-07 21:23:15 -0700 | |
---|---|---|
committer | 2020-07-07 21:23:15 -0700 | |
commit | ff34274fa4e2eff4942847c57243e140e7b12fc8 (patch) | |
tree | 117b1232056d27911f6e2e1b1405dc9d0c1c21a6 /Source/main.cpp | |
parent | 772d1b2347ecaa3d8d9b27fa32b7bb703b22aee4 (diff) | |
download | WarpX-ff34274fa4e2eff4942847c57243e140e7b12fc8.tar.gz WarpX-ff34274fa4e2eff4942847c57243e140e7b12fc8.tar.zst WarpX-ff34274fa4e2eff4942847c57243e140e7b12fc8.zip |
Raise the stack limit when running with cuda (#1154)
* raise the stack limit when running with cuda
* fix comment + only do this in debug mode
Diffstat (limited to 'Source/main.cpp')
-rw-r--r-- | Source/main.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/main.cpp b/Source/main.cpp index ee0db6960..4bbdce2da 100644 --- a/Source/main.cpp +++ b/Source/main.cpp @@ -34,6 +34,11 @@ int main(int argc, char* argv[]) amrex::Initialize(argc,argv); + // in Debug mode, we need a larger stack limit than usual bc of the parser. +#if defined(AMREX_USE_CUDA) && defined(AMREX_DEBUG) + AMREX_CUDA_SAFE_CALL(cudaDeviceSetLimit(cudaLimitStackSize, 20*1024)); +#endif + ConvertLabParamsToBoost(); CheckGriddingForRZSpectral(); |