Commit 8ac44e55 authored by yangguo@chromium.org's avatar yangguo@chromium.org

MIPS: Fix wrong asserts in SeqStringSetCharGenerator.

This commit fixes wrong asserts in commit r13230 (1929bb68).

BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/11943003
Patch from Akos Palfi <palfia@homejinni.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13427 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 9cf627b3
......@@ -533,9 +533,9 @@ void SeqStringSetCharGenerator::Generate(MacroAssembler* masm,
__ Check(eq, "Non-smi value", at, Operand(zero_reg));
__ lw(at, FieldMemOperand(string, String::kLengthOffset));
__ Check(lt, "Index is too large", at, Operand(index));
__ Check(lt, "Index is too large", index, Operand(at));
__ Check(ge, "Index is negative", index, Operand(Smi::FromInt(0)));
__ Check(ge, "Index is negative", index, Operand(zero_reg));
__ lw(at, FieldMemOperand(string, HeapObject::kMapOffset));
__ lbu(at, FieldMemOperand(at, Map::kInstanceTypeOffset));
......@@ -543,9 +543,9 @@ void SeqStringSetCharGenerator::Generate(MacroAssembler* masm,
__ And(at, at, Operand(kStringRepresentationMask | kStringEncodingMask));
static const uint32_t one_byte_seq_type = kSeqStringTag | kOneByteStringTag;
static const uint32_t two_byte_seq_type = kSeqStringTag | kTwoByteStringTag;
__ Check(eq, "Unexpected string type", at,
Operand(encoding == String::ONE_BYTE_ENCODING
? one_byte_seq_type : two_byte_seq_type));
__ Subu(at, at, Operand(encoding == String::ONE_BYTE_ENCODING
? one_byte_seq_type : two_byte_seq_type));
__ Check(eq, "Unexpected string type", at, Operand(zero_reg));
}
__ Addu(at,
......
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