ProfilerConfig.MethodTracing


public final class ProfilerConfig.MethodTracing extends ProfilerConfig


Summary

Public fields

static final boolean

This value is true if method tracing affects future performance measurement within the process on the current device.

Public constructors

Public fields

AFFECTS_MEASUREMENTS_ON_THIS_DEVICE

public static final boolean AFFECTS_MEASUREMENTS_ON_THIS_DEVICE

This value is true if method tracing affects future performance measurement within the process on the current device.

This is determined both by the OS version and ART mainline module version (if present).

If this value is true, no measurements can be made by microbenchmark after a method trace completes, and further benchmarks will throw rather than capturing invalid metrics until the next process restart.

You can use assumeFalse(MethodTracing.affectsMeasurementOnThisDevice) to skip tests that use method tracing, configure your profiler based on this flag, or select a different device to avoid runtime crashes.

Note that by default, microbenchmarks enable method tracing only when this value is false.

Method tracing is always performed after any measurement phases, so single method benchmark runs are not affected - throwing will happen starting with the 2nd benchmark in a suite (process invocation).

Public constructors

MethodTracing

Added in 1.2.0
public MethodTracing()