Following #516, where AdePT was restructured into two libraries, this issue documents how to leverage the library split into a cleaner file tree:
The final file tree could look like this:
AdePT/
include/
AdePT/
### NOTE: core/AdePTConfiguration.hh and integration/AdePTTrackingManager.hh
# are temporary to maintain backward compatibility with the user integration for a bit.
core/
AdePTConfiguration.hh # temporary compatibility forwarding header
integration/
AdePTTrackingManager.hh # temporary compatibility forwarding header
G4EmStandardPhysics_AdePT.hh # temporary compatibility forwarding header
G4EmStandardPhysics_HepEm.hh # temporary compatibility forwarding header
### Actual structure starts here: ###
g4integration/
AdePTConfiguration.hh
AdePTTrackingManager.hh
transport/
config/
AdePTTransportConfig.hh
support/
Macros.h
Global.h
Portability.hh
ResourceManagement.hh
ResourceManagement.cuh
PhysicalConstants.h
SystemOfUnits.h
AdePTPrecision.hh
containers/
Atomic.h
BlockData.h
MParray.h
MParrayT.h
SlotManager.cuh
mpmc_bounded_queue.h
VariableSizeObj.h
VariableSizeObjAllocator.h
random/
Ranluxpp.h
G4HepEmRandomEngineDeviceImpl.hh
ranluxpp/
helpers.h
mulmod.h
ranlux_lcg.h
g4hepem/
AdePTG4HepEmState.hh
tracks/
TrackData.h
Track.cuh
ParticleTypes.hh
queues/
TrackBuffer.hh
ParticleQueues.cuh
ParticleManager.cuh
steps/
GPUStep.hh
HostCircularBuffer.hh
DeviceStepBuffer.cuh
GPUStepRecording.cuh
GPUStepTransferManager.cuh
geometry/
GeometryAuxData.hh
WDTData.hh
state/
EventState.hh
GPUState.cuh
TransportStats.hh
DeviceGlobals.cuh
navigation/
AdePTNavigator.h
BVHNavigator.h
LoopNavigator.h
SurfNavigator.h
magneticfield/
existing magnetic-field headers
kernels/
existing electron/gamma/WDT kernel headers
src/
transport/
AdePTTransport.cc
AdePTTransport.cu
g4hepem/
AdePTG4HepEmState.cpp
steps/
HostCircularBuffer.cpp
# NOTE: the geometry.cu files and the gpu .cu files do not exist yet, this must be split, currently it is all in AsyncAdePTTransport.cuh
geometry/
GeometryUpload.cu
WDTUpload.cu
gpu/
GPUInit.cu
TransportLoop.cu
TransportKernels.cu
g4integration/
config/
AdePTConfiguration.cc
AdePTConfigurationMessenger.cc
tracking_managers/
AdePTTrackingManager.cc
AdePTThreadId.hh
G4HepEmTrackingManagerSpecialized.cc
geometry/
AdePTGeometryBridge.cpp
returned_steps/
# Note: currently those are all in a single file AdePTGeant4Integration.cpp, this needs to be split
AdePTGeant4Integration.cpp
G4TouchableBuilder.cpp
G4TrackBuilder.cpp
G4StepBuilder.cpp
DeferredStepReplay.cpp
physics_constructors/
G4EmStandardPhysics_AdePT.cc
G4EmStandardPhysics_HepEm.cc
cuda/
G4IntegrationRdcFacade.cu
To obtain this structure, a few things are needed:
Note that with this design copcore is going to be removed. In the current design of AdePT, there is no reason to keep a separate library, also it is not clear why e.g., the variablesizedobject lives in copcore but the atomics do not.
Following #516, where AdePT was restructured into two libraries, this issue documents how to leverage the library split into a cleaner file tree:
The final file tree could look like this:
To obtain this structure, a few things are needed:
AsyncAdePTTransportStruct.cuhin clearer pieces (done in Split AsyncAdePTTransportStruct headers into topical headers #614)AsyncAdePTTransport.cuhin clearer piecesAdePTGeant4Integrationin clearer piecesNote that with this design
copcoreis going to be removed. In the current design of AdePT, there is no reason to keep a separate library, also it is not clear why e.g., the variablesizedobject lives in copcore but the atomics do not.