Index: src/full-codegen/arm/full-codegen-arm.cc |
diff --git a/src/full-codegen/arm/full-codegen-arm.cc b/src/full-codegen/arm/full-codegen-arm.cc |
index c07438a2db813d366d7da75d4691e29735a98b10..724c8d7c4ab72d23193997404c7f4522af6bd2c6 100644 |
--- a/src/full-codegen/arm/full-codegen-arm.cc |
+++ b/src/full-codegen/arm/full-codegen-arm.cc |
@@ -3431,6 +3431,33 @@ void FullCodeGenerator::EmitIsSpecObject(CallRuntime* expr) { |
} |
+void FullCodeGenerator::EmitIsSimdObject(CallRuntime* expr) { |
+ ZoneList<Expression*>* args = expr->arguments(); |
+ DCHECK(args->length() == 1); |
+ |
+ VisitForAccumulatorValue(args->at(0)); |
+ |
+ Label materialize_true, materialize_false; |
+ Label* if_true = NULL; |
+ Label* if_false = NULL; |
+ Label* fall_through = NULL; |
+ context()->PrepareTest(&materialize_true, &materialize_false, &if_true, |
+ &if_false, &fall_through); |
+ |
+ __ JumpIfSmi(r0, if_false); |
+ Register map = r1; |
+ Register type_reg = r2; |
+ __ ldr(map, FieldMemOperand(r0, HeapObject::kMapOffset)); |
+ __ ldrb(type_reg, FieldMemOperand(map, Map::kInstanceTypeOffset)); |
+ __ sub(type_reg, type_reg, Operand(FIRST_SIMD_VALUE_TYPE)); |
+ __ cmp(type_reg, Operand(LAST_SIMD_VALUE_TYPE - FIRST_SIMD_VALUE_TYPE)); |
+ PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
+ Split(ls, if_true, if_false, fall_through); |
+ |
+ context()->Plug(if_true, if_false); |
+} |
+ |
+ |
void FullCodeGenerator::EmitIsUndetectableObject(CallRuntime* expr) { |
ZoneList<Expression*>* args = expr->arguments(); |
DCHECK(args->length() == 1); |
@@ -5076,6 +5103,30 @@ void FullCodeGenerator::EmitLiteralCompareTypeof(Expression* expr, |
__ JumpIfSmi(r0, if_false); |
__ CompareObjectType(r0, r0, r1, FLOAT32X4_TYPE); |
Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->int32x4_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, INT32X4_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->bool32x4_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, BOOL32X4_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->int16x8_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, INT16X8_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->bool16x8_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, BOOL16X8_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->int8x16_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, INT8X16_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
+ } else if (String::Equals(check, factory->bool8x16_string())) { |
+ __ JumpIfSmi(r0, if_false); |
+ __ CompareObjectType(r0, r0, r1, BOOL8X16_TYPE); |
+ Split(eq, if_true, if_false, fall_through); |
} else if (String::Equals(check, factory->boolean_string())) { |
__ CompareRoot(r0, Heap::kTrueValueRootIndex); |
__ b(eq, if_true); |