Index: src/ia32/ic-ia32.cc |
diff --git a/src/ia32/ic-ia32.cc b/src/ia32/ic-ia32.cc |
index 51f5b3a0c869c49c08b7c9d3e7333233994f065c..65c18269d826b5d12b24ad4e632a0daa55890dd7 100644 |
--- a/src/ia32/ic-ia32.cc |
+++ b/src/ia32/ic-ia32.cc |
@@ -78,11 +78,11 @@ static void GenerateStringDictionaryReceiverCheck(MacroAssembler* masm, |
// Check that the receiver is a valid JS object. |
__ mov(r1, FieldOperand(receiver, HeapObject::kMapOffset)); |
__ movzx_b(r0, FieldOperand(r1, Map::kInstanceTypeOffset)); |
- __ cmp(r0, FIRST_JS_OBJECT_TYPE); |
+ __ cmp(r0, FIRST_SPEC_OBJECT_TYPE); |
__ j(below, miss); |
// If this assert fails, we have to check upper bound too. |
- ASSERT(LAST_TYPE == JS_FUNCTION_TYPE); |
+ STATIC_ASSERT(LAST_TYPE == LAST_SPEC_OBJECT_TYPE); |
GenerateGlobalInstanceTypeCheck(masm, r0, miss); |
@@ -727,9 +727,13 @@ void KeyedStoreIC::GenerateGeneric(MacroAssembler* masm, |
__ j(not_zero, &slow); |
__ CmpInstanceType(edi, JS_ARRAY_TYPE); |
__ j(equal, &array); |
- // Check that the object is some kind of JS object. |
- __ CmpInstanceType(edi, FIRST_JS_OBJECT_TYPE); |
+ // Check that the object is some kind of JSObject. |
+ __ CmpInstanceType(edi, FIRST_JS_RECEIVER_TYPE); |
__ j(below, &slow); |
+ __ CmpInstanceType(edi, JS_PROXY_TYPE); |
+ __ j(equal, &slow); |
+ __ CmpInstanceType(edi, JS_FUNCTION_PROXY_TYPE); |
+ __ j(equal, &slow); |
// Object case: Check key against length in the elements array. |
// eax: value |