Index: src/assembler.cc |
diff --git a/src/assembler.cc b/src/assembler.cc |
index c0b54df8aa012f53552ee6cfd03f60dc0fee9f12..0b272f8b1b6df7d2fc47a9bef973e3072a4bf40b 100644 |
--- a/src/assembler.cc |
+++ b/src/assembler.cc |
@@ -1132,11 +1132,66 @@ ExternalReference ExternalReference::compute_output_frames_function( |
Redirect(isolate, FUNCTION_ADDR(Deoptimizer::ComputeOutputFrames))); |
} |
-static void trunc64_wrapper(double* param) { *param = trunc(*param); } |
+static void f32_trunc_wrapper(float* param) { *param = truncf(*param); } |
-ExternalReference ExternalReference::trunc64_wrapper_function( |
+ExternalReference ExternalReference::f32_trunc_wrapper_function( |
Isolate* isolate) { |
- return ExternalReference(Redirect(isolate, FUNCTION_ADDR(trunc64_wrapper))); |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f32_trunc_wrapper))); |
+} |
+ |
+static void f32_floor_wrapper(float* param) { *param = floorf(*param); } |
+ |
+ExternalReference ExternalReference::f32_floor_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f32_floor_wrapper))); |
+} |
+ |
+static void f32_ceil_wrapper(float* param) { *param = ceilf(*param); } |
+ |
+ExternalReference ExternalReference::f32_ceil_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f32_ceil_wrapper))); |
+} |
+ |
+static void f32_nearest_int_wrapper(float* param) { |
+ *param = nearbyintf(*param); |
+} |
+ |
+ExternalReference ExternalReference::f32_nearest_int_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference( |
+ Redirect(isolate, FUNCTION_ADDR(f32_nearest_int_wrapper))); |
+} |
+ |
+static void f64_trunc_wrapper(double* param) { *param = trunc(*param); } |
+ |
+ExternalReference ExternalReference::f64_trunc_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f64_trunc_wrapper))); |
+} |
+ |
+static void f64_floor_wrapper(double* param) { *param = floor(*param); } |
+ |
+ExternalReference ExternalReference::f64_floor_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f64_floor_wrapper))); |
+} |
+ |
+static void f64_ceil_wrapper(double* param) { *param = ceil(*param); } |
+ |
+ExternalReference ExternalReference::f64_ceil_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference(Redirect(isolate, FUNCTION_ADDR(f64_ceil_wrapper))); |
+} |
+ |
+static void f64_nearest_int_wrapper(double* param) { |
+ *param = nearbyint(*param); |
+} |
+ |
+ExternalReference ExternalReference::f64_nearest_int_wrapper_function( |
+ Isolate* isolate) { |
+ return ExternalReference( |
+ Redirect(isolate, FUNCTION_ADDR(f64_nearest_int_wrapper))); |
} |
ExternalReference ExternalReference::log_enter_external_function( |