Commit 983ed89a authored by vegorov@chromium.org's avatar vegorov@chromium.org

Ensure that empty descriptor array is marked before visiting any maps in marking phase.

Review URL: http://codereview.chromium.org/3318014

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5416 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 119f630b
...@@ -643,9 +643,13 @@ void MarkCompactCollector::PrepareForCodeFlushing() { ...@@ -643,9 +643,13 @@ void MarkCompactCollector::PrepareForCodeFlushing() {
#endif #endif
StaticMarkingVisitor::EnableCodeFlushing(true); StaticMarkingVisitor::EnableCodeFlushing(true);
// Ensure that empty descriptor array is marked. Method MarkDescriptorArray
// relies on it being marked before any other descriptor array.
MarkObject(Heap::raw_unchecked_empty_descriptor_array());
// Make sure we are not referencing the code from the stack. // Make sure we are not referencing the code from the stack.
for (StackFrameIterator it; !it.done(); it.Advance()) { for (StackFrameIterator it; !it.done(); it.Advance()) {
MarkCompactCollector::MarkObject(it.frame()->unchecked_code()); MarkObject(it.frame()->unchecked_code());
} }
// Iterate the archived stacks in all threads to check if // Iterate the archived stacks in all threads to check if
...@@ -656,7 +660,7 @@ void MarkCompactCollector::PrepareForCodeFlushing() { ...@@ -656,7 +660,7 @@ void MarkCompactCollector::PrepareForCodeFlushing() {
SharedFunctionInfoMarkingVisitor visitor; SharedFunctionInfoMarkingVisitor visitor;
CompilationCache::IterateFunctions(&visitor); CompilationCache::IterateFunctions(&visitor);
MarkCompactCollector::ProcessMarkingStack(); ProcessMarkingStack();
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment