aboutsummaryrefslogtreecommitdiff
path: root/libgo/go/math/log10.go
diff options
context:
space:
mode:
Diffstat (limited to 'libgo/go/math/log10.go')
-rw-r--r--libgo/go/math/log10.go18
1 files changed, 16 insertions, 2 deletions
diff --git a/libgo/go/math/log10.go b/libgo/go/math/log10.go
index 6d18baa..5204492 100644
--- a/libgo/go/math/log10.go
+++ b/libgo/go/math/log10.go
@@ -6,8 +6,22 @@ package math
// Log10 returns the decimal logarithm of x.
// The special cases are the same as for Log.
-func Log10(x float64) float64 { return Log(x) * (1 / Ln10) }
+func libc_log10(float64) float64 __asm__("log10")
+func Log10(x float64) float64 {
+ return libc_log10(x)
+}
+
+func log10(x float64) float64 {
+ return Log(x) * (1 / Ln10)
+}
// Log2 returns the binary logarithm of x.
// The special cases are the same as for Log.
-func Log2(x float64) float64 { return Log(x) * (1 / Ln2) }
+func libc_log2(float64) float64 __asm__("log2")
+func Log2(x float64) float64 {
+ return libc_log2(x)
+}
+
+func log2(x float64) float64 {
+ return Log(x) * (1 / Ln2)
+}