[K/N] Use already dereferenced weakReferee (KT-66371)
And prevent weak barriers from execution during STW Merge-request: KT-MR-14797 Merged-by: Alexey Glushko <aleksei.glushko@jetbrains.com>
This commit is contained in:
committed by
Space Team
parent
284d5437e5
commit
f2501ad424
@@ -87,6 +87,9 @@ void gc::mark::ConcurrentMark::runMainInSTW() {
|
||||
gc::processWeaks<DefaultProcessWeaksTraits>(gcHandle(), mm::SpecialRefRegistry::instance());
|
||||
|
||||
if (!terminateInSTW) {
|
||||
// Mutator threads execute weak barrier in "native" state. This hack maes them stop with the rest of the world.
|
||||
std::unique_lock markTerminationGuard(markTerminationMutex_);
|
||||
|
||||
stopTheWorld(gcHandle(), "GC stop the world #2: prepare to sweep");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user