Index: src/platform-win32.cc |
diff --git a/src/platform-win32.cc b/src/platform-win32.cc |
index 27433b25afd7a47d214efec550a2ea53e33fb373..261a946a869802cee9646eb1db7ec0939acc587c 100644 |
--- a/src/platform-win32.cc |
+++ b/src/platform-win32.cc |
@@ -199,11 +199,19 @@ UNARY_MATH_FUNCTION(sin, CreateTranscendentalFunction(TranscendentalCache::SIN)) |
UNARY_MATH_FUNCTION(cos, CreateTranscendentalFunction(TranscendentalCache::COS)) |
UNARY_MATH_FUNCTION(tan, CreateTranscendentalFunction(TranscendentalCache::TAN)) |
UNARY_MATH_FUNCTION(log, CreateTranscendentalFunction(TranscendentalCache::LOG)) |
+UNARY_MATH_FUNCTION(exp, CreateExpFunction()) |
UNARY_MATH_FUNCTION(sqrt, CreateSqrtFunction()) |
#undef MATH_FUNCTION |
+void lazily_initialize_fast_exp() { |
+ if (fast_exp_function == NULL) { |
+ init_fast_exp_function(); |
+ } |
+} |
+ |
+ |
void MathSetup() { |
#ifdef _WIN64 |
init_modulo_function(); |
@@ -212,6 +220,7 @@ void MathSetup() { |
init_fast_cos_function(); |
init_fast_tan_function(); |
init_fast_log_function(); |
+ // fast_exp is initialized lazily. |
init_fast_sqrt_function(); |
} |