See https://github.com/cms-patatrack/pixeltrack-standalone/pull/239#discussion_r729532105. This is currently done in `alpaka`, we should try if it works well on native CUDA and HIP.