ENH: use intrinsics for isnan, isfinite and isinf

Use of intrinsics avoids expensive function calls in tight loops on x86
cpus where these operations are implemented in hardware while still
retaining same portability.
More than doubles performance of np.isnan/isinf/isfinite.