patch up error behavior of sqrt after 244ec92f55bb5433898c5a859a0cb452aafa1673