Index: src/assembler.cc |
diff --git a/src/assembler.cc b/src/assembler.cc |
index 030d15c514d1dbc4c667b2f7875f38c3a7c8a03c..b0b44fd980e0721bc7e32f7f4ec6bacccf7dc911 100644 |
--- a/src/assembler.cc |
+++ b/src/assembler.cc |
@@ -816,6 +816,39 @@ static double mod_two_doubles(double x, double y) { |
} |
+static double math_sin_double(double x) { |
+ return sin(x); |
+} |
+ |
+ |
+static double math_cos_double(double x) { |
+ return cos(x); |
+} |
+ |
+ |
+static double math_log_double(double x) { |
+ return log(x); |
+} |
+ |
+ |
+ExternalReference ExternalReference::math_sin_double_function() { |
+ return ExternalReference(Redirect(FUNCTION_ADDR(math_sin_double), |
+ FP_RETURN_CALL)); |
+} |
+ |
+ |
+ExternalReference ExternalReference::math_cos_double_function() { |
+ return ExternalReference(Redirect(FUNCTION_ADDR(math_cos_double), |
+ FP_RETURN_CALL)); |
+} |
+ |
+ |
+ExternalReference ExternalReference::math_log_double_function() { |
+ return ExternalReference(Redirect(FUNCTION_ADDR(math_log_double), |
+ FP_RETURN_CALL)); |
+} |
+ |
+ |
// Helper function to compute x^y, where y is known to be an |
// integer. Uses binary decomposition to limit the number of |
// multiplications; see the discussion in "Hacker's Delight" by Henry |