Skip to content

Commit

Permalink
Add missing calls to increase CUDA stack limit
Browse files Browse the repository at this point in the history
This fixes crashes on my system when running with cms2018.gdml in
Example11 and Example14.
  • Loading branch information
hahnjo committed Oct 17, 2023
1 parent 0e51a1e commit 8d1ab09
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions examples/Example11/example11.cu
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ __global__ void FinishIteration(AllParticleQueues all, const GlobalScoring *scor
void example11(const vecgeom::cxx::VPlacedVolume *world, int numParticles, double energy)
{
NVTXTracer tracer("Geometry");
COPCORE_CUDA_CHECK(vecgeom::cxx::CudaDeviceSetStackLimit(8192));
auto &cudaManager = vecgeom::cxx::CudaManager::Instance();
cudaManager.LoadGeometry(world);
cudaManager.Synchronize();
Expand Down
1 change: 1 addition & 0 deletions examples/Example14/AdeptIntegration.cu
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ __global__ void ClearAllQueues(AllParticleQueues all)

bool AdeptIntegration::InitializeGeometry(const vecgeom::cxx::VPlacedVolume *world)
{
COPCORE_CUDA_CHECK(vecgeom::cxx::CudaDeviceSetStackLimit(8192));
// Upload geometry to GPU.
auto &cudaManager = vecgeom::cxx::CudaManager::Instance();
cudaManager.LoadGeometry(world);
Expand Down

0 comments on commit 8d1ab09

Please sign in to comment.