| 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 "v8.h" | 5 #include "v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_IA32 | 7 #if V8_TARGET_ARCH_IA32 |
| 8 | 8 |
| 9 #include "bootstrapper.h" | 9 #include "bootstrapper.h" |
| 10 #include "codegen.h" | 10 #include "codegen.h" |
| (...skipping 3312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3323 j(cc, condition_met, condition_met_distance); | 3323 j(cc, condition_met, condition_met_distance); |
| 3324 } | 3324 } |
| 3325 | 3325 |
| 3326 | 3326 |
| 3327 void MacroAssembler::CheckMapDeprecated(Handle<Map> map, | 3327 void MacroAssembler::CheckMapDeprecated(Handle<Map> map, |
| 3328 Register scratch, | 3328 Register scratch, |
| 3329 Label* if_deprecated) { | 3329 Label* if_deprecated) { |
| 3330 if (map->CanBeDeprecated()) { | 3330 if (map->CanBeDeprecated()) { |
| 3331 mov(scratch, map); | 3331 mov(scratch, map); |
| 3332 mov(scratch, FieldOperand(scratch, Map::kBitField3Offset)); | 3332 mov(scratch, FieldOperand(scratch, Map::kBitField3Offset)); |
| 3333 and_(scratch, Immediate(Smi::FromInt(Map::Deprecated::kMask))); | 3333 and_(scratch, Immediate(Map::Deprecated::kMask)); |
| 3334 j(not_zero, if_deprecated); | 3334 j(not_zero, if_deprecated); |
| 3335 } | 3335 } |
| 3336 } | 3336 } |
| 3337 | 3337 |
| 3338 | 3338 |
| 3339 void MacroAssembler::JumpIfBlack(Register object, | 3339 void MacroAssembler::JumpIfBlack(Register object, |
| 3340 Register scratch0, | 3340 Register scratch0, |
| 3341 Register scratch1, | 3341 Register scratch1, |
| 3342 Label* on_black, | 3342 Label* on_black, |
| 3343 Label::Distance on_black_near) { | 3343 Label::Distance on_black_near) { |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3501 Check(less_equal, kLiveBytesCountOverflowChunkSize); | 3501 Check(less_equal, kLiveBytesCountOverflowChunkSize); |
| 3502 } | 3502 } |
| 3503 | 3503 |
| 3504 bind(&done); | 3504 bind(&done); |
| 3505 } | 3505 } |
| 3506 | 3506 |
| 3507 | 3507 |
| 3508 void MacroAssembler::EnumLength(Register dst, Register map) { | 3508 void MacroAssembler::EnumLength(Register dst, Register map) { |
| 3509 STATIC_ASSERT(Map::EnumLengthBits::kShift == 0); | 3509 STATIC_ASSERT(Map::EnumLengthBits::kShift == 0); |
| 3510 mov(dst, FieldOperand(map, Map::kBitField3Offset)); | 3510 mov(dst, FieldOperand(map, Map::kBitField3Offset)); |
| 3511 and_(dst, Immediate(Smi::FromInt(Map::EnumLengthBits::kMask))); | 3511 and_(dst, Immediate(Map::EnumLengthBits::kMask)); |
| 3512 SmiTag(dst); |
| 3512 } | 3513 } |
| 3513 | 3514 |
| 3514 | 3515 |
| 3515 void MacroAssembler::CheckEnumCache(Label* call_runtime) { | 3516 void MacroAssembler::CheckEnumCache(Label* call_runtime) { |
| 3516 Label next, start; | 3517 Label next, start; |
| 3517 mov(ecx, eax); | 3518 mov(ecx, eax); |
| 3518 | 3519 |
| 3519 // Check if the enum length field is properly initialized, indicating that | 3520 // Check if the enum length field is properly initialized, indicating that |
| 3520 // there is an enum cache. | 3521 // there is an enum cache. |
| 3521 mov(ebx, FieldOperand(ecx, HeapObject::kMapOffset)); | 3522 mov(ebx, FieldOperand(ecx, HeapObject::kMapOffset)); |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3612 if (ms.shift() > 0) sar(edx, ms.shift()); | 3613 if (ms.shift() > 0) sar(edx, ms.shift()); |
| 3613 mov(eax, dividend); | 3614 mov(eax, dividend); |
| 3614 shr(eax, 31); | 3615 shr(eax, 31); |
| 3615 add(edx, eax); | 3616 add(edx, eax); |
| 3616 } | 3617 } |
| 3617 | 3618 |
| 3618 | 3619 |
| 3619 } } // namespace v8::internal | 3620 } } // namespace v8::internal |
| 3620 | 3621 |
| 3621 #endif // V8_TARGET_ARCH_IA32 | 3622 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |