Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(48)

Unified Diff: src/arm/lithium-codegen-arm.cc

Issue 12567004: ARM: Optimsisation of ECMA ToInt32. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/arm/lithium-codegen-arm.cc
diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc
index 6fd97972c3facddf5b0463003f498fc510b62d0c..02c47d4bca56c697d7c2f4602a2d572f982a21a5 100644
--- a/src/arm/lithium-codegen-arm.cc
+++ b/src/arm/lithium-codegen-arm.cc
@@ -5246,12 +5246,8 @@ void LCodeGen::DoDeferredTaggedToI(LTaggedToI* instr) {
__ sub(scratch1, input_reg, Operand(kHeapObjectTag));
__ vldr(double_scratch2, scratch1, HeapNumber::kValueOffset);
- __ EmitECMATruncate(input_reg,
- double_scratch2,
- double_scratch,
- scratch1,
- scratch2,
- scratch3);
+ __ ECMAToInt32VFP(input_reg, double_scratch2, double_scratch,
+ scratch1, scratch2, scratch3);
} else {
CpuFeatureScope scope(masm(), VFP3);
@@ -5349,12 +5345,8 @@ void LCodeGen::DoDoubleToI(LDoubleToI* instr) {
if (instr->truncating()) {
Register scratch3 = ToRegister(instr->temp2());
- __ EmitECMATruncate(result_reg,
- double_input,
- double_scratch,
- scratch1,
- scratch2,
- scratch3);
+ __ ECMAToInt32VFP(result_reg, double_input, double_scratch,
+ scratch1, scratch2, scratch3);
} else {
__ TryDoubleToInt32Exact(result_reg, double_input, double_scratch);
// Deoptimize if the input wasn't a int32 (inside a double).

Powered by Google App Engine
This is Rietveld 408576698