From bc998d034f45d1828a8663b2eed928faf22a7d01 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Thu, 14 Sep 2017 17:11:35 +0000 Subject: libgo: update to go1.9 Reviewed-on: https://go-review.googlesource.com/63753 From-SVN: r252767 --- libgo/go/math/erf.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'libgo/go/math/erf.go') diff --git a/libgo/go/math/erf.go b/libgo/go/math/erf.go index 8ddd5f9..e2a0422 100644 --- a/libgo/go/math/erf.go +++ b/libgo/go/math/erf.go @@ -186,6 +186,13 @@ const ( // Erf(-Inf) = -1 // Erf(NaN) = NaN func Erf(x float64) float64 { + return libc_erf(x) +} + +//extern erf +func libc_erf(float64) float64 + +func erf(x float64) float64 { const ( VeryTiny = 2.848094538889218e-306 // 0x0080000000000000 Small = 1.0 / (1 << 28) // 2**-28 @@ -263,6 +270,13 @@ func Erf(x float64) float64 { // Erfc(-Inf) = 2 // Erfc(NaN) = NaN func Erfc(x float64) float64 { + return libc_erfc(x) +} + +//extern erfc +func libc_erfc(float64) float64 + +func erfc(x float64) float64 { const Tiny = 1.0 / (1 << 56) // 2**-56 // special cases switch { -- cgit v1.1