| Index: runtime/vm/profiler.cc
|
| diff --git a/runtime/vm/profiler.cc b/runtime/vm/profiler.cc
|
| index 840f438359bb62e7f0aca86a650467282959d987..9aa683b7caf609e29592e1750a20d962b83e47d3 100644
|
| --- a/runtime/vm/profiler.cc
|
| +++ b/runtime/vm/profiler.cc
|
| @@ -52,6 +52,10 @@ DEFINE_FLAG(bool, profile_vm, true, "Always collect native stack traces.");
|
| #else
|
| DEFINE_FLAG(bool, profile_vm, false, "Always collect native stack traces.");
|
| #endif
|
| +DEFINE_FLAG(bool,
|
| + profile_vm_allocation,
|
| + false,
|
| + "Collect native stack traces when tracing Dart allocations.");
|
|
|
| #ifndef PRODUCT
|
|
|
| @@ -1182,7 +1186,7 @@ void Profiler::SampleAllocation(Thread* thread, intptr_t cid) {
|
| Sample* sample = SetupSample(thread, sample_buffer, os_thread->trace_id());
|
| sample->SetAllocationCid(cid);
|
|
|
| - if (FLAG_profile_vm) {
|
| + if (FLAG_profile_vm_allocation) {
|
| ProfilerNativeStackWalker native_stack_walker(
|
| (isolate != NULL) ? isolate->main_port() : ILLEGAL_PORT, sample,
|
| sample_buffer, stack_lower, stack_upper, pc, fp, sp);
|
|
|