Use floating-point literals in TrackUtils.h - #15689
Conversation
This shows up during profiling ITS GPU kernels. The division on line 176 is forced to be calculated in double. This costed 23% of stalls in some kernels. I am not sure if the precision is required here? At least in local tests it did not affect the ITS tracking output (<0.1%).
|
That was definitely a bug, and is a common case which can force GPUs to do double arithmetics instead of single. Obviously this is a matter of taste, but in my code I prefer to use use float constants. |
|
Hi David, that's how I found it. I profiled ITS kernels which were forced to do double here. I first did I like you suggested 1.f and Sandro suggested to use value_T. I honestly do not have a preference here. |
|
If that was intentional, one should put a comment, looks like an oversight. OK, I don't care too much for the style if it is outside my code :). |
This shows up during profiling ITS GPU kernels.
The division on line 176 is forced to be calculated in double. This costed 23% of stalls in some kernels.
I am not sure if the precision is required here?
At least in local tests it did not affect the ITS tracking output (<0.1%).