There are a few #ifdef CUDAs around the cleanup of registeredTreepieces---a vector of treepieces on each node. This information could be useful elsewhere (e.g. the TreePieceReplica code) so all these CUDA ifdefs could be removed and the cleanup done in one place. I suggest the start of Main::buildTree().
There are a few
#ifdef CUDA
s around the cleanup of registeredTreepieces---a vector of treepieces on each node. This information could be useful elsewhere (e.g. the TreePieceReplica code) so all these CUDA ifdefs could be removed and the cleanup done in one place. I suggest the start of Main::buildTree().