Index: src/ia32/stub-cache-ia32.cc |
=================================================================== |
--- src/ia32/stub-cache-ia32.cc (revision 3821) |
+++ src/ia32/stub-cache-ia32.cc (working copy) |
@@ -229,14 +229,13 @@ |
Register scratch1, |
Register scratch2, |
Label* miss) { |
- Label load_length, check_wrapper; |
+ Label check_wrapper; |
// Check if the object is a string leaving the instance type in the |
// scratch register. |
GenerateStringCheck(masm, receiver, scratch1, miss, &check_wrapper); |
// Load length from the string and convert to a smi. |
- __ bind(&load_length); |
__ mov(eax, FieldOperand(receiver, String::kLengthOffset)); |
__ SmiTag(eax); |
__ ret(0); |
@@ -250,7 +249,9 @@ |
// directly if it is. |
__ mov(scratch2, FieldOperand(receiver, JSValue::kValueOffset)); |
GenerateStringCheck(masm, scratch2, scratch1, miss, miss); |
- __ jmp(&load_length); |
+ __ mov(eax, FieldOperand(scratch2, String::kLengthOffset)); |
+ __ SmiTag(eax); |
+ __ ret(0); |
} |