diff --git a/runtime/vm/profiler.cc b/runtime/vm/profiler.cc index 826285eefd6..ba9684da803 100644 --- a/runtime/vm/profiler.cc +++ b/runtime/vm/profiler.cc @@ -909,12 +909,7 @@ Sample* SampleBlockBuffer::ReserveSampleImpl(Isolate* isolate, if (block != nullptr) { block->MarkCompleted(); if (!Isolate::IsSystemIsolate(isolate)) { - Thread* mutator = isolate->IGNORE_RACE(mutator_thread)(); - // The mutator thread might be NULL if we sample in the middle of - // Thread::Enter/ExitIsolate. - if ((mutator != nullptr) && isolate->TrySetHasCompletedBlocks()) { - mutator->ScheduleInterrupts(Thread::kVMInterrupt); - } + isolate->TrySetHasCompletedBlocks(); } } return next->ReserveSample(); diff --git a/runtime/vm/thread.cc b/runtime/vm/thread.cc index 50611597b40..dde8b3f9a16 100644 --- a/runtime/vm/thread.cc +++ b/runtime/vm/thread.cc @@ -857,13 +857,6 @@ ErrorPtr Thread::HandleInterrupts(uword interrupt_bits) { } heap()->CheckFinalizeMarking(this); -#if !defined(PRODUCT) - // TODO(dartbug.com/60508): Allow profiling of isolate-group-shared code. - if (isolate() != nullptr && isolate()->TakeHasCompletedBlocks()) { - Profiler::ProcessCompletedBlocks(isolate()); - } -#endif // !defined(PRODUCT) - #if !defined(PRODUCT) || defined(FORCE_INCLUDE_SAMPLING_HEAP_PROFILER) HeapProfileSampler& sampler = heap_sampler(); if (sampler.ShouldSetThreadSamplingInterval()) {