Removed unnecessary math functions, use SetExceptionMask