Skip to content

Commit bd75ca2

Browse files
committed
ITS: do not use NAN in helpers for new ROCm
fixes: /home/fschlepp/alice/sw/SOURCES/O2/dev_head/0/Detectors/ITSMFT/ITS/tracking/include/ITStracking/TrackHelpers.h:65:60: warning: use of NaN is undefined behavior due to the currently enabled floating-point options [-Wnan-infinity-disabled] 65 | float ca = NAN, sa = NAN, snp = NAN, q2pt = NAN, q2pt2 = NAN; | ^~~ /opt/rocm-7.1.1/lib/llvm/lib/clang/20/include/float.h:174:16: note: expanded from macro 'NAN' 174 | # define NAN (__builtin_nanf("")) Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
1 parent 44c45da commit bd75ca2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Detectors/ITSMFT/ITS/tracking/include/ITStracking/TrackHelpers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ GPUdi() o2::track::TrackParCov buildTrackSeed(const Cluster& cluster1,
6262
const float bz,
6363
const bool reverse = false)
6464
{
65-
float ca = NAN, sa = NAN, snp = NAN, q2pt = NAN, q2pt2 = NAN;
65+
float ca = constants::UnsetValue, sa = constants::UnsetValue, snp = constants::UnsetValue, q2pt = constants::UnsetValue, q2pt2 = constants::UnsetValue;
6666
o2::gpu::CAMath::SinCos(tf3.alphaTrackingFrame, sa, ca);
6767
const float sign = reverse ? -1.f : 1.f;
6868
const float x1 = (cluster1.xCoordinate * ca) + (cluster1.yCoordinate * sa);

0 commit comments

Comments
 (0)