| Index: src/crankshaft/ia32/lithium-codegen-ia32.cc
|
| diff --git a/src/crankshaft/ia32/lithium-codegen-ia32.cc b/src/crankshaft/ia32/lithium-codegen-ia32.cc
|
| index 02a9d58c32d36ab62c6a1691bc9a6a1bfc4e1a2e..1ede1f22b6bf2e6df6c144f03efab25dee73b2b0 100644
|
| --- a/src/crankshaft/ia32/lithium-codegen-ia32.cc
|
| +++ b/src/crankshaft/ia32/lithium-codegen-ia32.cc
|
| @@ -2445,14 +2445,11 @@ void LCodeGen::EmitClassOfTest(Label* is_true,
|
| // Assuming the following assertions, we can use the same compares to test
|
| // for both being a function type and being in the object type range.
|
| STATIC_ASSERT(NUM_OF_CALLABLE_SPEC_OBJECT_TYPES == 2);
|
| - STATIC_ASSERT(FIRST_NONCALLABLE_SPEC_OBJECT_TYPE ==
|
| - FIRST_JS_RECEIVER_TYPE + 1);
|
| STATIC_ASSERT(LAST_NONCALLABLE_SPEC_OBJECT_TYPE ==
|
| LAST_JS_RECEIVER_TYPE - 1);
|
| STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE);
|
| __ CmpObjectType(input, FIRST_JS_RECEIVER_TYPE, temp);
|
| __ j(below, is_false);
|
| - __ j(equal, is_true);
|
| __ CmpInstanceType(temp, LAST_JS_RECEIVER_TYPE);
|
| __ j(equal, is_true);
|
| } else {
|
| @@ -2460,9 +2457,9 @@ void LCodeGen::EmitClassOfTest(Label* is_true,
|
| // actual type and do a signed compare with the width of the type range.
|
| __ mov(temp, FieldOperand(input, HeapObject::kMapOffset));
|
| __ movzx_b(temp2, FieldOperand(temp, Map::kInstanceTypeOffset));
|
| - __ sub(Operand(temp2), Immediate(FIRST_NONCALLABLE_SPEC_OBJECT_TYPE));
|
| + __ sub(Operand(temp2), Immediate(FIRST_JS_RECEIVER_TYPE));
|
| __ cmp(Operand(temp2), Immediate(LAST_NONCALLABLE_SPEC_OBJECT_TYPE -
|
| - FIRST_NONCALLABLE_SPEC_OBJECT_TYPE));
|
| + FIRST_JS_RECEIVER_TYPE));
|
| __ j(above, is_false);
|
| }
|
|
|
|
|