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

Unified Diff: runtime/vm/gc_sweeper.cc

Issue 836593002: Deletion barrier: Distinguish+verify field initialization in ia32 generated code. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 11 months 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 | « runtime/vm/flow_graph_optimizer.cc ('k') | runtime/vm/heap.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/gc_sweeper.cc
===================================================================
--- runtime/vm/gc_sweeper.cc (revision 42713)
+++ runtime/vm/gc_sweeper.cc (working copy)
@@ -44,6 +44,10 @@
obj_size = free_end - current;
if (is_executable) {
memset(reinterpret_cast<void*>(current), 0xcc, obj_size);
+ } else {
+#if defined(DEBUG)
+ memset(reinterpret_cast<void*>(current), Heap::kZapByte, obj_size);
+#endif // DEBUG
}
if ((current != start) || (free_end != end)) {
// Only add to the free list if not covering the whole page.
@@ -77,7 +81,9 @@
while (current < end) {
RawObject* cur_obj = RawObject::FromAddr(current);
ASSERT(!cur_obj->IsMarked());
- current += cur_obj->Size();
+ intptr_t obj_size = cur_obj->Size();
+ memset(reinterpret_cast<void*>(current), Heap::kZapByte, obj_size);
+ current += obj_size;
}
#endif // DEBUG
return words_to_end;
« no previous file with comments | « runtime/vm/flow_graph_optimizer.cc ('k') | runtime/vm/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698