| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <limits.h> // For LONG_MIN, LONG_MAX. | 5 #include <limits.h> // For LONG_MIN, LONG_MAX. |
| 6 | 6 |
| 7 #include "src/v8.h" | 7 #include "src/v8.h" |
| 8 | 8 |
| 9 #if V8_TARGET_ARCH_MIPS64 | 9 #if V8_TARGET_ARCH_MIPS64 |
| 10 | 10 |
| (...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 478 Context::SECURITY_TOKEN_INDEX * kPointerSize; | 478 Context::SECURITY_TOKEN_INDEX * kPointerSize; |
| 479 | 479 |
| 480 ld(scratch, FieldMemOperand(scratch, token_offset)); | 480 ld(scratch, FieldMemOperand(scratch, token_offset)); |
| 481 ld(at, FieldMemOperand(at, token_offset)); | 481 ld(at, FieldMemOperand(at, token_offset)); |
| 482 Branch(miss, ne, scratch, Operand(at)); | 482 Branch(miss, ne, scratch, Operand(at)); |
| 483 | 483 |
| 484 bind(&same_contexts); | 484 bind(&same_contexts); |
| 485 } | 485 } |
| 486 | 486 |
| 487 | 487 |
| 488 // Compute the hash code from the untagged key. This must be kept in sync with |
| 489 // ComputeIntegerHash in utils.h and KeyedLoadGenericStub in |
| 490 // code-stub-hydrogen.cc |
| 488 void MacroAssembler::GetNumberHash(Register reg0, Register scratch) { | 491 void MacroAssembler::GetNumberHash(Register reg0, Register scratch) { |
| 489 // First of all we assign the hash seed to scratch. | 492 // First of all we assign the hash seed to scratch. |
| 490 LoadRoot(scratch, Heap::kHashSeedRootIndex); | 493 LoadRoot(scratch, Heap::kHashSeedRootIndex); |
| 491 SmiUntag(scratch); | 494 SmiUntag(scratch); |
| 492 | 495 |
| 493 // Xor original key with a seed. | 496 // Xor original key with a seed. |
| 494 xor_(reg0, reg0, scratch); | 497 xor_(reg0, reg0, scratch); |
| 495 | 498 |
| 496 // Compute the hash code from the untagged key. This must be kept in sync | 499 // Compute the hash code from the untagged key. This must be kept in sync |
| 497 // with ComputeIntegerHash in utils.h. | 500 // with ComputeIntegerHash in utils.h. |
| (...skipping 5601 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6099 } | 6102 } |
| 6100 if (ms.shift() > 0) sra(result, result, ms.shift()); | 6103 if (ms.shift() > 0) sra(result, result, ms.shift()); |
| 6101 srl(at, dividend, 31); | 6104 srl(at, dividend, 31); |
| 6102 Addu(result, result, Operand(at)); | 6105 Addu(result, result, Operand(at)); |
| 6103 } | 6106 } |
| 6104 | 6107 |
| 6105 | 6108 |
| 6106 } } // namespace v8::internal | 6109 } } // namespace v8::internal |
| 6107 | 6110 |
| 6108 #endif // V8_TARGET_ARCH_MIPS64 | 6111 #endif // V8_TARGET_ARCH_MIPS64 |
| OLD | NEW |