Is there a way to set a float variable to infinity from inside a kernel? (The C constant INFINITY doesn't work, as it's not explicitly passed into the kernel.)
I didn't try it, but maybe a = 1.0 / 0.0; works for infinity and a = 0.0 / 0.0; for NaN - as for checking for these values, I have no clue
Good idea! The resulting kernel code contains:
"zeroop" seems to suggest that no operation will be performed in the assembled machine code. Is that correct?
Retrieving data ...