Commit 82398cc6 authored by Omer Katz's avatar Omer Katz Committed by V8 LUCI CQ

[heap] MinorMC implies separate GC phases

This is a necessary assumption for concurrent marking in MinorMC and
will simplify the code as it allows MinorMC to reuse the same marking
bitmap as full GCs.

Bug: v8:12612
Change-Id: I5e9be45c7d84320721ce7f7578dee1eb972d6f6a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3732933Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#81465}
parent 9d642b11
...@@ -1934,6 +1934,7 @@ DEFINE_NEG_NEG_IMPLICATION(text_is_readable, partial_constant_pool) ...@@ -1934,6 +1934,7 @@ DEFINE_NEG_NEG_IMPLICATION(text_is_readable, partial_constant_pool)
DEFINE_BOOL(trace_minor_mc_parallel_marking, false, DEFINE_BOOL(trace_minor_mc_parallel_marking, false,
"trace parallel marking for the young generation") "trace parallel marking for the young generation")
DEFINE_BOOL(minor_mc, false, "perform young generation mark compact GCs") DEFINE_BOOL(minor_mc, false, "perform young generation mark compact GCs")
DEFINE_IMPLICATION(minor_mc, separate_gc_phases)
// //
// Dev shell flags // Dev shell flags
......
...@@ -2606,6 +2606,7 @@ void Heap::MarkCompact() { ...@@ -2606,6 +2606,7 @@ void Heap::MarkCompact() {
void Heap::MinorMarkCompact() { void Heap::MinorMarkCompact() {
DCHECK(FLAG_minor_mc); DCHECK(FLAG_minor_mc);
CHECK_EQ(NOT_IN_GC, gc_state());
DCHECK(new_space()); DCHECK(new_space());
if (FLAG_trace_incremental_marking && !incremental_marking()->IsStopped()) { if (FLAG_trace_incremental_marking && !incremental_marking()->IsStopped()) {
......
...@@ -5623,6 +5623,7 @@ class MinorMarkCompactCollector::RootMarkingVisitor : public RootVisitor { ...@@ -5623,6 +5623,7 @@ class MinorMarkCompactCollector::RootMarkingVisitor : public RootVisitor {
}; };
void MinorMarkCompactCollector::CollectGarbage() { void MinorMarkCompactCollector::CollectGarbage() {
DCHECK(!heap()->mark_compact_collector()->in_use());
// Minor MC does not support processing the ephemeron remembered set. // Minor MC does not support processing the ephemeron remembered set.
DCHECK(heap()->ephemeron_remembered_set_.empty()); DCHECK(heap()->ephemeron_remembered_set_.empty());
......
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