Releases: google/perfetto
Releases · google/perfetto
Perfetto v29.0
v29.0 - 2022-09-06:
Tracing service and probes:
* Add support for only tracing selected syscalls. By selecting only syscalls
of interest, usage of the trace buffer and performance impact on device
is reduced.
* Add support for parsing DSI ftrace events.
Trace Processor:
* Make calling NotifyEndOfFile more than once an error: this was deprecated
in v28. Flush should be used instead for all by the final call.
* Add parsing and ingestion for V4L2 events.
* Upgraded SQLite to 3.39.2.
UI:
* Add support for searching Android log events.
* Group kernel wakelock tracks into a single track group.
SDK:
* Added support for startup tracing. Tracing can be started in an app
before it connects to the tracing service.
The data sources which are started for startup tracing, will
be automatically adopted to normal tracing session once we start
normal tracing session.
* Added the |first_packet_on_sequence| boolean which is set the first packet
emitted on each TraceWriter.
Perfetto v28.0
v28.0 - 2022-08-02:
Tracing service and probes:
* Add android.statsd datasource.
* Removed log spam about sys.trace.traced_started in standalone builds.
* Changed kallsyms parsing in traced_probes (ftrace) to be always
synchronous (when starting the trace, rather than on the first batch).
* Added ksyms_mem_policy = KSYMS_RETAIN_FOREVER config to avoid destroying
and re-parsing kallsysm repeatedly in benchmark runs.
* Improve heap profiling shutdown: now the shared memory buffer where
alloc/free records are stored is properly flushed when stopping the data
source.
* Fixed race condition in the daemonization path of perfetto --background.
It would cause daemonization failures if the TTY is destroyed immediately.
Trace Processor:
* Deprecate calling NotifyEndOfFile more than once: Flush should instead be
used for all but the final call.
* Added ingestion and visualization of I2C transactions.
UI:
* Changed callstack sampling selection: selecting one sample now only shows
one stacktrace, selecting multiple samples shows the aggregation.
SDK:
* Fixed a bug (b/239725760) that would cause abstract sockets using the
"@name" syntax in PERFETTO_CONSUMER_SOCK_NAME/PERFETTO_PRODUCER_SOCK_NAME
to have a trailing \0 in the socket name. This breaks interoperability
with adb forwarding. This is a tracing protocol breaking change. Nobody
seems to be relying on @abstract syntax across different versions of
client vs service.
* Changed the mangling scheme for protozero enums nested in another message:
instead of OuterClass_Enum_VALUE, the enum values will be just named
VALUE with the enum itself wrapped in a perfetto_pbzero_enum_OuterClass
namespace to prevent naming collisions. This will allow the users
to alias the enum directly and use throughout their code.
The exact name mangling scheme is a carry-over from libprotobuf and
an internal implementation detail, so nobody should be relying on that.
* Added protozero::EnumToString() to convert enum keys to string literals.
Perfetto v27.1
SDK:
* Added an API for shutting down Perfetto.
Perfetto v27.0
v27.0 - 2022-07-01:
Tracing service and probes:
* Fix rare crash due to watchdog timeout being too short.
Trace Processor:
* Removed enable_perfetto_x64_cpu_opt by default for x64 MacOS
since it caused issues for CIs.
* Improved performance of filtering and sorting on most queries.
UI:
* Changed sorting of process groups to take slice count and presence of
perf profiles into account.
SDK:
*
Perfetto v26.1
v26.1 - 2022-06-13:
Trace Processor:
* Fixed build failures on Windows.
v26.0 - 2022-06-13:
Tracing service and probes:
* Added wildcard (*) support when targeting processes by their command line
in the Android perf profiler ("linux.perf" data source) and Java heap
snapshots ("android.java_hprof").
* Added support for kernel thread sampling, and kernel-only callstacks in
the Android perf profiler.
* Fixed rare crash when parsing zero-length ftrace __data_loc strings.
* Fixed rare crash on 4.19 kernel when encountering unexpected zero-padded
ftrace pages.
* Removed capturing of thread_time_in_state (per-UID, per-OOM-adj time).
The data was unused and subsumed by correlating sched data with power
rail monitors.
Trace Processor:
* Added CREATE_VIEW_FUNCTION operator to define a SQL function that can
return a temporary table and yield multiple rows and columns.
* Changed kernel threads to be represented as single-thread processes in
Linux system traces. The (incorrect) legacy behaviour was to treat them
as threads of the kthreadd process.
* Added ABS_TIME_STR function which converts a trace timestamp to
an ISO8601 string.
* Added ingestion for phase='R' events, used by performance.{now,mark}().
* Changed 'trace_to_text' to be named 'traceconv'. The source
location also moved from 'tools/trace_to_text' to 'src/traceconv'.
* Changed compiler flags, added -mavx2. The previous patch in v22.0 was
supposed to add AVX2 support but added only AVX.
* Changed the handling of the last per-cpu sched slices: rather than
extending the last event to the end of the trace, the last scheduling
event has a -1 duration. UIs are supposed to deal with visual extension.
* Removed android_thread_time_in_state metric. It was an experiment and was
unused.
* Removed `instant` table. All instant events are now 0-duration events in
the `slice` table.
* Removed the /raw_query REST endpoint from --httpd. This will break very
old clients that have not switched over the new streaming-based /query
endoint or even newer /websocket.
UI:
* Changed detail panel to separate slice args from generic slice properties.
* Automatically enabled sched_compact when generating trace configs for
Android S+ targets.
SDK:
* Added option for recording thread CPU times at the beginning and end of
each slice.
* Added perfetto::DynamicString() to use non-literal strings as event names
in the TRACE_EVENT API.
* Remove the pre-SDK consumer_api_deprecated interface. It was introduced
for iorapd, now deleted from the Android tree.
Perfetto v25.0
v25.0 - 2022-04-01:
Tracing service and probes:
* Added prebuilts for mac-arm64.
* Removed merged trace and config protos from Bazel. Embedder should
instead depend on the non-merged proto targets.
* Added FtraceConfig.disable_generic_events. If set, the ftrace data source
will not emit events for which it doesn't have a compile-time proto
message.
* Added ingestion support for cros_ec (CrOS sensors) ftrace events.
* Added ingestion support for kvm trace events.
* Added reporting of atrace failures. Now they are bubbled up to the UI
rather than causing atrace data to be silently missing.
Trace Processor:
* Added prebuilts for mac-arm64.
* Changed LIKE comparisions to be case-insenstive. This reverts the change
introduced in v22. GLOB should be used where case senstive searches are
desired; built-in metrics continue to require the use of GLOB.
* Added an optional dependency from trace processor onto a subset of
sources from llvm-project for function name demangling. Bazel embedders
might need to update their PERFETTO_CONFIG in perfetto_cfg.bzl to opt in
or out of the new dependency. See
perfetto/bazel/standalone/perfetto_cfg.bzl for details.
UI:
* Added flow arrows between binder transaction pairs (request/reply
and async send/async recv).
SDK:
* Added support for writing typed proto messages inside DebugAnnotations.
* Added support for delta encoding of timestamps for TrackEvents.
To disable it, refer to `disable_incremental_timestamps` flag in
`track_event_config.proto`.
Tools:
* Added support of gzip-compressed traces to traceconv.
* Changed `traceconv text` to use an internal proto->pbtx converter rather
than relying on libprotobuf. It could cause some small divergencies in the
output format vs past releases.
* Added tools/cpu_profile helper script to capture traces with callstack
samples.
Perfetto v24.2
v24.2 - 2022-02-10:
SDK:
* Revert of incremental timestamps, introduced in v24.0.
Some clients were depending on non-incremental timestamps.
Future releases will re-enable this but offer an opt-out.
v24.1 - 2022-02-09:
Tracing service and probes:
* Fixed build failures on Windows.
Trace Processor:
* Fixed build failures on Windows.
v24.0 - 2022-02-08:
Tracing service and probes:
* Added "cpufreq_period_ms" in data source "linux.sys_stats" to poll
/sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq periodically.
* Added support for Trusty TEE workqueue events.
* Added support for more PMU events in traced_perf.
* Changed output format of perfetto --query. Made the output more compact
and added a summary of ongoing tracing sessions for the caller UID.
* Changed timeout for traced stall detection from 2s to 4s.
* Changed internal buffer management to split trace filtering in smaller
tasks and avoid too large memory allocation when filtering.
* Fixed a bug that could cause producers to see Flush() requests after an
OnStop() and mis-behave if the tracing session is extremely short.
Trace Processor:
* Added support for passing multiple SQL statements to ExecuteQuery(). All
queries will be executed fully, with the returned iterator yielding rows
for the final statement.
* Added support for multi-line SQL comments; previously only single line
comments were supported.
UI:
* Added support for parsing instant events from legacy systrace formats.
* Added ingestion and visualization for inet_sock_set_state and
tcp_retransmit_skb events, showing TCP connections on dedicated tracks.
* Changed HTTP+RPC to use the /websocket endpoint available in newer
versions of trace_processor --httpd.
* Changed text selection/copy: now allowed by default for DOM elements.
* Changed search to also lookup slices by ID when the term is a number.
* Changed postMessage() API, suppressed confirmation dialog when the opener
is in the same origin, for cases when the UI is self-hosted.
SDK:
* Changed timestamps emitted by the SDK to be incremental by default, using
ClockSnapshot + TracePacketDefaults.
Perfetto v24.1
v24.1 - 2022-02-09:
Tracing service and probes:
* Fixed build failures on Windows.
Trace Processor:
* Fixed build failures on Windows.
UI:
*
SDK:
*
v24.0 - 2022-02-08:
Tracing service and probes:
* Added "cpufreq_period_ms" in data source "linux.sys_stats" to poll
/sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq periodically.
* Added support for Trusty TEE workqueue events.
* Added support for more PMU events in traced_perf.
* Changed output format of perfetto --query. Made the output more compact
and added a summary of ongoing tracing sessions for the caller UID.
* Changed timeout for traced stall detection from 2s to 4s.
* Changed internal buffer management to split trace filtering in smaller
tasks and avoid too large memory allocation when filtering.
* Fixed a bug that could cause producers to see Flush() requests after an
OnStop() and mis-behave if the tracing session is extremely short.
Trace Processor:
* Added support for passing multiple SQL statements to ExecuteQuery(). All
queries will be executed fully, with the returned iterator yielding rows
for the final statement.
* Added support for multi-line SQL comments; previously only single line
comments were supported.
UI:
* Added support for parsing instant events from legacy systrace formats.
* Added ingestion and visualization for inet_sock_set_state and
tcp_retransmit_skb events, showing TCP connections on dedicated tracks.
* Changed HTTP+RPC to use the /websocket endpoint available in newer
versions of trace_processor --httpd.
* Changed text selection/copy: now allowed by default for DOM elements.
* Changed search to also lookup slices by ID when the term is a number.
* Changed postMessage() API, suppressed confirmation dialog when the opener
is in the same origin, for cases when the UI is self-hosted.
SDK:
*
Perfetto v23.0
v23.0 - 2022-01-11:
Tracing service and probes:
* Added workaround for a kernel ftrace bug causing some "comm" fields to be
not null-terminated. https://github.com/torvalds/linux/commit/f0a5157803 .
* Added ability to talk to the newer AIDL-based health hal in traced_probes.
It still falls back on the older HIDL interface for older devices.
Trace Processor:
* Changed the argument for the trace path in constructor of TraceProcessor
in the Python API from |file_path| to |trace|.
|file_path| is deprecated and may be removed in the future.
* Changed the Python API constructor. Now it takes a TraceProcessorConfig
instead of passing parameters directly. This may break existing code
but migration should be trivial (all current options are still
supported).
* Fixed a HTTP keepalive bug in trace_processor --httpd. The bug, introduced
in v22.0, caused each RPC request to close the connection, effectively
defeating the 'Connection: Keep-Alive', after each query made by the UI.
* Added parsing of netif_receive_skb events from proto traces.
* Added android_netperf metric based on netif events.
* Fixed a bug that would cause fetch errors when loading traces > 32 MB when
using trace_processor --httpd.
* Added a workaround to tokenize properly /proc/pid/cmdline for chrome
processes on Linux/CrOS. Chrome rewrites its cmdline replacing \0 -> ' '.
UI:
*
SDK:
Perfetto v22.1
v22.1 - 2021-12-07:
Tracing service and probes:
* Added workaround for a Linux kernel bug causing some ftrace strings to
be non-null-terminated (https://github.com/torvalds/linux/commit/f0a5157).
Trace Processor:
* Fixed build failures on Windows.
v22.0 - 2021-12-03:
Tracing service and probes:
* Added Android SDK version to the SystemInfo trace packet.
* Changed compiler flags. Assume recent x64 CPUs (-msse4.2 -mavx -mpopcnt).
This behavior affects only standalone builds and can be changed by setting
enable_perfetto_x64_cpu_opt=false in the GN args.
* The java heap profiler now rescans all the processes every time for
continous_dump_config. The scan_pids_only_on_start can be used to restore
the old behavior.
* Added support for building on ARM Macs.
* Added support for the rss_stat_throttled event on Android via
FtraceConfig.throttle_rss_stat. In newer Android kernels the base rss_stat
event is now unthrottled. rss_stat used to be throttled by a downstream
kernel change, unnecessary after https://lkml.org/lkml/2021/10/25/1411 .
atrace.rc configures throttling from userspace at boot.
* Fixed a bug that caused IPCs to stall traced and hit the watchdog if in
the middle of a suspend/resume. Switched from SND_TIMEO to poll(POLLOUT).
* Added "linux.sysfs_power" data source to poll /sys/class/power_supply/
and report periodically battery charge and drain rate if supported.
Trace Processor:
* Speeded up proto trace ingestion by 2x (~20 MB/s -> ~40 MB/s).
* Changed LIKE comparisions to be case-senstive. This may break existing
queries but was a necessary from a performance perspective.
Going forward, GLOB must be used, instead of LIKE, for checked in metrics
to avoid unnecessary slowdowns.
* Changed compiler flags, assume recent x64 CPUs (see above).
* Changed how displayTimeUnit is handled in JSON traces to match catapult.
* Added websocket endpoint to RPC interface to reduce query latency.
* Added support for hot-reloading metrics (see //docs/analysis/metrics.md).
UI:
* Added ability to save/restore record config. Remember last used config.
* Fixed bug causing the recording page to hold onto the USB interface making
adb unusable after a recording session.
SDK:
* Added UpdateDataSource() descriptor IPC endpoint to allow updates of the
data source capabilities (e.g., category list for track event).