3 ms·
Interrupts on NaNs are extremely expensive to implement on vector and GPU processors. We learned that in the Cray-1 days. Handling the exception in a vector ipe
by dbcurtis 9y ago
Interrupts on NaNs are extremely expensive to implement on vector and GPU processors. We learned that in the Cray-1 days. Handling the exception in a vector iperation kicks off an ultra-expensive context switch. A NaN does not break the flow.
- dnautics 9y agoIt seems like an antipattern. If your execution time is bound by an "ultra expensive context switch" occurring when you hit a Nan, then something is wrong with your algorithm.
- geezerjay 9y ago> Interrupts on NaNs are extremely expensive to implement on vector and GPU processors. That's ok, because NaNs are exceptional responses to numerical errors thrown during number crunching, indicating that something failed unexpectedly and the output is crap.