Skip to content

Optimization of TOF hitfinder.

@fweig Following up on our discussion here !1475 (comment 36319) I have now tried the following things:

  1. Using digis instead of pointers in cbm::algo::Clusterizer.
  2. Using digis instead of pointers in both cbm::algo::Clusterizer and cbm::algo::Hitfind.
  3. Using digis instead of pointers only in cbm::algo::Hitfind.

Options 2 and 3 both imply that the cbm::algo::Clusterizer instances receive contiguous blocks of memory, as the digis (rather than the pointers to digis) are sorted by RPC. In option 2, the digis are then additionally sorted by channel index.

As it turns out, of these, option 3 is the fastest, on all of the machines that I tested, and yields a 10-20 percent speedup compared to the "all pointers" version. With hindsight, this makes some sense, as we get the best of both worlds: Each cbm::algo::Clusterizer receives a compact block of memory as input, but the subsequent operations on this block are as light-weight as possible.

This will probably also have some advantages, once I attempt parallelization.

Assigning to myself and will set to merge immediately, in order to proceed with further things.

FYI @v.friese @f.uhlig @j.decuveland @p.-a.loizeau

Merge request reports