Chromium Code Reviews| Index: src/incremental-marking.cc |
| diff --git a/src/incremental-marking.cc b/src/incremental-marking.cc |
| index 0e53a380ac717a7741ddf172327a821dc0631d94..b34f50c8fed139988af21428e87751b03c0dd2b2 100644 |
| --- a/src/incremental-marking.cc |
| +++ b/src/incremental-marking.cc |
| @@ -305,6 +305,22 @@ bool IncrementalMarking::WorthActivating() { |
| } |
| +void IncrementalMarking::ActivateGeneratedStub(Code* stub) { |
| + ASSERT(RecordWriteStub::GetMode(stub) == |
| + RecordWriteStub::STORE_BUFFER_ONLY); |
|
Lasse Reichstein
2011/07/12 06:44:16
Indent to '(' or four chars from start of statemen
Vyacheslav Egorov (Chromium)
2011/07/12 11:17:11
Done.
|
| + |
| + if (!IsMarking()) { |
| + // Initially stub is generated in STORE_BUFFER_ONLY mode thus |
| + // we don't need to do anything if incremental marking is |
| + // not active. |
| + } else if (IsCompacting()) { |
| + RecordWriteStub::Patch(stub, RecordWriteStub::INCREMENTAL_COMPACTION); |
| + } else { |
| + RecordWriteStub::Patch(stub, RecordWriteStub::INCREMENTAL); |
| + } |
| +} |
| + |
| + |
| static void PatchIncrementalMarkingRecordWriteStubs( |
| Heap* heap, RecordWriteStub::Mode mode) { |
| NumberDictionary* stubs = heap->code_stubs(); |