ENH: npymath: handle clog edge cases more carefully.