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 "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_IA32 | 7 #if V8_TARGET_ARCH_IA32 |
8 | 8 |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/base/division-by-constant.h" | 10 #include "src/base/division-by-constant.h" |
(...skipping 1338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1349 times_pointer_size, | 1349 times_pointer_size, |
1350 SeededNumberDictionary::kElementsStartOffset)); | 1350 SeededNumberDictionary::kElementsStartOffset)); |
1351 if (i != (kNumberDictionaryProbes - 1)) { | 1351 if (i != (kNumberDictionaryProbes - 1)) { |
1352 j(equal, &done); | 1352 j(equal, &done); |
1353 } else { | 1353 } else { |
1354 j(not_equal, miss); | 1354 j(not_equal, miss); |
1355 } | 1355 } |
1356 } | 1356 } |
1357 | 1357 |
1358 bind(&done); | 1358 bind(&done); |
1359 // Check that the value is a normal propety. | 1359 // Check that the value is a field property. |
1360 const int kDetailsOffset = | 1360 const int kDetailsOffset = |
1361 SeededNumberDictionary::kElementsStartOffset + 2 * kPointerSize; | 1361 SeededNumberDictionary::kElementsStartOffset + 2 * kPointerSize; |
1362 DCHECK_EQ(NORMAL, 0); | 1362 DCHECK_EQ(FIELD, 0); |
1363 test(FieldOperand(elements, r2, times_pointer_size, kDetailsOffset), | 1363 test(FieldOperand(elements, r2, times_pointer_size, kDetailsOffset), |
1364 Immediate(PropertyDetails::TypeField::kMask << kSmiTagSize)); | 1364 Immediate(PropertyDetails::TypeField::kMask << kSmiTagSize)); |
1365 j(not_zero, miss); | 1365 j(not_zero, miss); |
1366 | 1366 |
1367 // Get the value at the masked, scaled index. | 1367 // Get the value at the masked, scaled index. |
1368 const int kValueOffset = | 1368 const int kValueOffset = |
1369 SeededNumberDictionary::kElementsStartOffset + kPointerSize; | 1369 SeededNumberDictionary::kElementsStartOffset + kPointerSize; |
1370 mov(result, FieldOperand(elements, r2, times_pointer_size, kValueOffset)); | 1370 mov(result, FieldOperand(elements, r2, times_pointer_size, kValueOffset)); |
1371 } | 1371 } |
1372 | 1372 |
(...skipping 2074 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3447 if (mag.shift > 0) sar(edx, mag.shift); | 3447 if (mag.shift > 0) sar(edx, mag.shift); |
3448 mov(eax, dividend); | 3448 mov(eax, dividend); |
3449 shr(eax, 31); | 3449 shr(eax, 31); |
3450 add(edx, eax); | 3450 add(edx, eax); |
3451 } | 3451 } |
3452 | 3452 |
3453 | 3453 |
3454 } } // namespace v8::internal | 3454 } } // namespace v8::internal |
3455 | 3455 |
3456 #endif // V8_TARGET_ARCH_IA32 | 3456 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |