1. 29 Sep, 2021 1 commit
  2. 28 Sep, 2021 1 commit
  3. 27 Sep, 2021 1 commit
    • Benjamin Morgan's avatar
      Export required flags for VecGeom as compile options · 9016a352
      Benjamin Morgan authored
      Identified in upstream use by Geant4 - required compiler flags for
      using VecGeom (ISA and alignment) are not exported as CMake usage
      requirements for the imported targets. The client is required to use
      the CMake variables set in VecGeomConfig.cmake, and this may not be
      obvious or always done.
      
      Add the required flags to the VecGeom target as CMake compile options
      so they are propagated to clients linking the imported target.
      
      NB: These flags currently must be added to VecGeom's build-time
      CMAKE_CXX_FLAGS as well to support CUDA builds. This leads to repitition
      of the flags on the compile command line, but there should be no
      side effects as the flags used do not change behaviour when repeated.
      9016a352
  4. 11 Sep, 2021 2 commits
  5. 03 Sep, 2021 1 commit
  6. 02 Sep, 2021 2 commits
  7. 01 Sep, 2021 1 commit
  8. 25 Aug, 2021 10 commits
  9. 20 Aug, 2021 5 commits
  10. 11 Aug, 2021 2 commits
  11. 05 Aug, 2021 2 commits
  12. 04 Aug, 2021 1 commit
  13. 03 Aug, 2021 1 commit
  14. 26 Jul, 2021 3 commits
  15. 22 Jul, 2021 2 commits
  16. 15 Jul, 2021 2 commits
  17. 07 Jul, 2021 3 commits
    • Stephan Hageboeck's avatar
      Activate bulk copying of PlacedVolume and Transformation3D to the GPU. · 5d8be486
      Stephan Hageboeck authored
      When copying host instances with bulk transfers, fewer kernels are
      invoked, which reduces the overhead, and construction on the GPU runs in
      parallel.
      With the trackML geometry, bulk copying placed volumes and transformations
      is 10x faster on a TeslaV100 GPU.
      The total transfer time reduces 5x.
      
      Diff of AdePT't example11 synchronising trackML.gdml:
      ```
      New:                                                            Old:
      INFO: using default trackML.gdml for option -gdml_name		INFO: using default trackML.gdml for option -gdml_name
      INFO: using default 0 for option -cache_depth			INFO: using default 0 for option -cache_depth
      INFO: using default 1 for option -particles			INFO: using default 1 for option -particles
      INFO: using default 100 for option -energy			INFO: using default 100 for option -energy
      (II) vgdml::Frontend::Load: VecGeom millimeter is 1		(II) vgdml::Frontend::Load: VecGeom millimeter is 1
      Starting synchronization to GPU.				Starting synchronization to GPU.
      Allocating geometry on GPU...Allocating logical volumes... OK	Allocating geometry on GPU...Allocating logical volumes... OK
      Allocating unplaced volumes... OK: #elems in alloc_mem=2, mem	Allocating unplaced volumes... OK: #elems in alloc_mem=2, mem
      Allocating placed volumes... OK					Allocating placed volumes... OK
      Allocating navigation index table... OK				Allocating navigation index table... OK
      Allocating transformations... OK: #elems in alloc_mem=5, mem_	Allocating transformations... OK: #elems in alloc_mem=5, mem_
      Allocating daughter lists... OK					Allocating daughter lists... OK
       geometry OK: #elems in alloc_mem=7, mem_map=38013, dau_gpu_c	 geometry OK: #elems in alloc_mem=7, mem_map=38013, dau_gpu_c
      NUMBER OF PLACED VOLUMES 18789					NUMBER OF PLACED VOLUMES 18789
      NUMBER OF UNPLACED VOLUMES 145					NUMBER OF UNPLACED VOLUMES 145
      Copying geometry to GPU...					Copying geometry to GPU...
      
      Copying logical volumes... OK;	TIME NEEDED 0.000615441s      |	Copying logical volumes... OK;	TIME NEEDED 0.000695619s
      Copying unplaced volumes... OK;	TIME NEEDED 0.000503695s      |	Copying unplaced volumes... OK;	TIME NEEDED 0.000411785s
      Copying transformations_... OK;	TIME NEEDED 0.00657207s       |	Copying transformations_... OK;	TIME NEEDED 0.0558993s
      Copying placed volumes... OK;	TIME NEEDED 0.00866507s       |	Copying placed volumes... OK;	TIME NEEDED 0.0913828s
      Copying daughter arrays... OK;	TIME NEEDED 0.00384211s       |	Copying daughter arrays... OK;	TIME NEEDED 0.00892739s
      Geometry synchronized to GPU in 0.036591 s.		      |	Geometry synchronized to GPU in 0.173805 s.
           ---  InitElectronData ... 					     ---  InitElectronData ...
           ---  BuildELossTables ...					     ---  BuildELossTables ...
      ...								...
      iter  221 -- tracks in flight:     2 energy deposition:    77	iter  221 -- tracks in flight:     2 energy deposition:    77
      iter  222 -- tracks in flight:     0 energy deposition:    77	iter  222 -- tracks in flight:     0 energy deposition:    77
      Run time: 0.0552					      |	Run time: 0.0532
      ```
      5d8be486
    • Stephan Hageboeck's avatar
    • Stephan Hageboeck's avatar
      Implement functions for bulk-copying of placed volumes to GPU. · 4c0d19fb
      Stephan Hageboeck authored
      Instead of starting one kernel to construct one placed volume on the GPU, one can
      collect all instances of the same type, and construct these in a single kernel call.
      This drastically reduces the number of kernel calls for larger geometries.
      
      This required defining template functions that
      - Collect all constructor arguments in arrays
      - Copy those to the GPU
      - Run all constructors in parallel
      - Free the memory occupied by the constructor arguments.
      
      For each type of placed volumes, the helper ConstructManyOnGPU<Type> must be instantiated
      explicitly in the cxx namespace, as implicit instantiation doesn't reach it automatically.
      Most instantiations happen via the macros in PlacedVolume.h, but PlacedAssembly, UnplacedExtruded,
      UnplacedMultiUnion and UnplacedTesselated needed explicit dummy instantiations to fix linker
      problems.
      4c0d19fb