arm: Fix Smi check in SubStringStub::Generate

R=ulan@chromium.org

Review URL: https://codereview.chromium.org/256743007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21050 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 99d9712b
......@@ -3391,10 +3391,8 @@ void SubStringStub::Generate(MacroAssembler* masm) {
// Make sure first argument is a string.
__ ldr(r0, MemOperand(sp, kStringOffset));
// Do a JumpIfSmi, but fold its jump into the subsequent string test.
__ SmiTst(r0);
Condition is_string = masm->IsObjectStringType(r0, r1, ne);
ASSERT(is_string == eq);
__ JumpIfSmi(r0, &runtime);
Condition is_string = masm->IsObjectStringType(r0, r1);
__ b(NegateCondition(is_string), &runtime);
Label single_char;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment