[vm] Do not interrupt mutator when SampleBlock is complete
This code was added when samples streaming was implemented and should not be necessary. Let background thread drain samples instead. This significantly reduces the overhead of activating profiler when using NativeRuntime.streamTimelineTo from 2-3x to ~10% in AOT mode and around ~20-25% in JIT. TEST=ci Change-Id: I4c6026f832d6a952b24323632b4126df6a6a6964 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/464183 Reviewed-by: Ryan Macnak <rmacnak@google.com> Commit-Queue: Slava Egorov <vegorov@google.com>
This commit is contained in:
committed by
Commit Queue
parent
2509b87755
commit
badeb15e5d
@@ -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()) {
|
||||
|
||||
Reference in New Issue
Block a user