Index: src/ia32/code-stubs-ia32.cc |
diff --git a/src/ia32/code-stubs-ia32.cc b/src/ia32/code-stubs-ia32.cc |
index aa890051ac46f70243b3521a2d63bf2dc907bdbd..ad9d4799196f3cfeecba6729dd60eecfff77e6d0 100644 |
--- a/src/ia32/code-stubs-ia32.cc |
+++ b/src/ia32/code-stubs-ia32.cc |
@@ -2895,74 +2895,6 @@ void StringHelper::GenerateCopyCharacters(MacroAssembler* masm, |
} |
-void StringHelper::GenerateHashInit(MacroAssembler* masm, |
- Register hash, |
- Register character, |
- Register scratch) { |
- // hash = (seed + character) + ((seed + character) << 10); |
- if (masm->serializer_enabled()) { |
- __ LoadRoot(scratch, Heap::kHashSeedRootIndex); |
- __ SmiUntag(scratch); |
- __ add(scratch, character); |
- __ mov(hash, scratch); |
- __ shl(scratch, 10); |
- __ add(hash, scratch); |
- } else { |
- int32_t seed = masm->isolate()->heap()->HashSeed(); |
- __ lea(scratch, Operand(character, seed)); |
- __ shl(scratch, 10); |
- __ lea(hash, Operand(scratch, character, times_1, seed)); |
- } |
- // hash ^= hash >> 6; |
- __ mov(scratch, hash); |
- __ shr(scratch, 6); |
- __ xor_(hash, scratch); |
-} |
- |
- |
-void StringHelper::GenerateHashAddCharacter(MacroAssembler* masm, |
- Register hash, |
- Register character, |
- Register scratch) { |
- // hash += character; |
- __ add(hash, character); |
- // hash += hash << 10; |
- __ mov(scratch, hash); |
- __ shl(scratch, 10); |
- __ add(hash, scratch); |
- // hash ^= hash >> 6; |
- __ mov(scratch, hash); |
- __ shr(scratch, 6); |
- __ xor_(hash, scratch); |
-} |
- |
- |
-void StringHelper::GenerateHashGetHash(MacroAssembler* masm, |
- Register hash, |
- Register scratch) { |
- // hash += hash << 3; |
- __ mov(scratch, hash); |
- __ shl(scratch, 3); |
- __ add(hash, scratch); |
- // hash ^= hash >> 11; |
- __ mov(scratch, hash); |
- __ shr(scratch, 11); |
- __ xor_(hash, scratch); |
- // hash += hash << 15; |
- __ mov(scratch, hash); |
- __ shl(scratch, 15); |
- __ add(hash, scratch); |
- |
- __ and_(hash, String::kHashBitMask); |
- |
- // if (hash == 0) hash = 27; |
- Label hash_not_zero; |
- __ j(not_zero, &hash_not_zero, Label::kNear); |
- __ mov(hash, Immediate(StringHasher::kZeroHash)); |
- __ bind(&hash_not_zero); |
-} |
- |
- |
void SubStringStub::Generate(MacroAssembler* masm) { |
Label runtime; |