Chromium Code Reviews| Index: src/heap.cc |
| diff --git a/src/heap.cc b/src/heap.cc |
| index 6a6afc022e54aff302e78a78abf2ecdaaf7dd423..57ab8796739445d31f48ca6434ac26c1cc289f89 100644 |
| --- a/src/heap.cc |
| +++ b/src/heap.cc |
| @@ -3862,6 +3862,11 @@ MaybeObject* Heap::CopyCode(Code* code) { |
| ASSERT(!isolate_->code_range()->exists() || |
| isolate_->code_range()->contains(code->address())); |
| new_code->Relocate(new_addr - old_addr); |
| + |
| + // Make sure new object is handled properly by the GC. |
| + incremental_marking()->RecordWrites(new_code); |
|
Michael Starzinger
2013/05/14 16:43:10
So I looked into this write-barrier and I don't th
|
| + // RecordWrites(new_code->address(), 0, Code::kHeaderSize); |
| + |
| return new_code; |
| } |