Index: src/arm/ic-arm.cc |
=================================================================== |
--- src/arm/ic-arm.cc (revision 6762) |
+++ src/arm/ic-arm.cc (working copy) |
@@ -115,6 +115,9 @@ |
Register name, |
Register scratch1, |
Register scratch2) { |
+ // Assert that name contains a string. |
+ if (FLAG_debug_code) __ AbortIfNotString(name); |
+ |
// Compute the capacity mask. |
const int kCapacityOffset = StringDictionary::kHeaderSize + |
StringDictionary::kCapacityIndex * kPointerSize; |
@@ -843,7 +846,14 @@ |
// -- lr : return address |
// ----------------------------------- |
+ // Check if the name is a string. |
+ Label miss; |
+ __ tst(r2, Operand(kSmiTagMask)); |
+ __ b(eq, &miss); |
+ __ IsObjectJSStringType(r2, r0, &miss); |
+ |
GenerateCallNormal(masm, argc); |
+ __ bind(&miss); |
GenerateMiss(masm, argc); |
} |