Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(452)

Unified Diff: src/heap/incremental-marking.cc

Issue 1542113002: Do not mark from native code. Check color and call incremental marker instead. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/arm64/macro-assembler-arm64.cc ('k') | src/ia32/code-stubs-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/incremental-marking.cc
diff --git a/src/heap/incremental-marking.cc b/src/heap/incremental-marking.cc
index 838f9d0b6bf29c599fea927dda50c28c07ab295b..52d0ca4e51b6e297c04c94bfb686116722d32bba 100644
--- a/src/heap/incremental-marking.cc
+++ b/src/heap/incremental-marking.cc
@@ -50,8 +50,12 @@ IncrementalMarking::IncrementalMarking(Heap* heap)
bool IncrementalMarking::BaseRecordWrite(HeapObject* obj, Object* value) {
HeapObject* value_heap_obj = HeapObject::cast(value);
MarkBit value_bit = Marking::MarkBitFrom(value_heap_obj);
+ DCHECK(!Marking::IsImpossible(value_bit));
+
MarkBit obj_bit = Marking::MarkBitFrom(obj);
+ DCHECK(!Marking::IsImpossible(obj_bit));
bool is_black = Marking::IsBlack(obj_bit);
+
if (is_black && Marking::IsWhite(value_bit)) {
WhiteToGreyAndPush(value_heap_obj, value_bit);
RestartIfNotMarking();
« no previous file with comments | « src/arm64/macro-assembler-arm64.cc ('k') | src/ia32/code-stubs-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698