| 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 #if V8_TARGET_ARCH_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
| 6 | 6 |
| 7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
| 8 #include "src/api-arguments.h" | 8 #include "src/api-arguments.h" |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
| (...skipping 3172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3183 regs_.RestoreCallerSaveRegisters(masm, save_fp_regs_mode()); | 3183 regs_.RestoreCallerSaveRegisters(masm, save_fp_regs_mode()); |
| 3184 } | 3184 } |
| 3185 | 3185 |
| 3186 | 3186 |
| 3187 void RecordWriteStub::CheckNeedsToInformIncrementalMarker( | 3187 void RecordWriteStub::CheckNeedsToInformIncrementalMarker( |
| 3188 MacroAssembler* masm, | 3188 MacroAssembler* masm, |
| 3189 OnNoNeedToInformIncrementalMarker on_no_need, | 3189 OnNoNeedToInformIncrementalMarker on_no_need, |
| 3190 Mode mode) { | 3190 Mode mode) { |
| 3191 Label object_is_black, need_incremental, need_incremental_pop_object; | 3191 Label object_is_black, need_incremental, need_incremental_pop_object; |
| 3192 | 3192 |
| 3193 __ mov(regs_.scratch0(), Immediate(~Page::kPageAlignmentMask)); | |
| 3194 __ and_(regs_.scratch0(), regs_.object()); | |
| 3195 __ mov(regs_.scratch1(), | |
| 3196 Operand(regs_.scratch0(), | |
| 3197 MemoryChunk::kWriteBarrierCounterOffset)); | |
| 3198 __ sub(regs_.scratch1(), Immediate(1)); | |
| 3199 __ mov(Operand(regs_.scratch0(), | |
| 3200 MemoryChunk::kWriteBarrierCounterOffset), | |
| 3201 regs_.scratch1()); | |
| 3202 __ j(negative, &need_incremental); | |
| 3203 | |
| 3204 // Let's look at the color of the object: If it is not black we don't have | 3193 // Let's look at the color of the object: If it is not black we don't have |
| 3205 // to inform the incremental marker. | 3194 // to inform the incremental marker. |
| 3206 __ JumpIfBlack(regs_.object(), | 3195 __ JumpIfBlack(regs_.object(), |
| 3207 regs_.scratch0(), | 3196 regs_.scratch0(), |
| 3208 regs_.scratch1(), | 3197 regs_.scratch1(), |
| 3209 &object_is_black, | 3198 &object_is_black, |
| 3210 Label::kNear); | 3199 Label::kNear); |
| 3211 | 3200 |
| 3212 regs_.Restore(masm); | 3201 regs_.Restore(masm); |
| 3213 if (on_no_need == kUpdateRememberedSetOnNoNeedToInformIncrementalMarker) { | 3202 if (on_no_need == kUpdateRememberedSetOnNoNeedToInformIncrementalMarker) { |
| (...skipping 2256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5470 kStackUnwindSpace, nullptr, return_value_operand, | 5459 kStackUnwindSpace, nullptr, return_value_operand, |
| 5471 NULL); | 5460 NULL); |
| 5472 } | 5461 } |
| 5473 | 5462 |
| 5474 #undef __ | 5463 #undef __ |
| 5475 | 5464 |
| 5476 } // namespace internal | 5465 } // namespace internal |
| 5477 } // namespace v8 | 5466 } // namespace v8 |
| 5478 | 5467 |
| 5479 #endif // V8_TARGET_ARCH_IA32 | 5468 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |