• Home
Name Date Size #Lines LOC

..--

scroll_jank/04-Jul-2025-1,492997

READMED04-Jul-20251.4 KiB158

android_input.sqlD04-Jul-20254.9 KiB15191

chrome_scrolls.sqlD04-Jul-202528.6 KiB639427

cpu_powerups.sqlD04-Jul-20255.8 KiB190102

event_latency.sqlD04-Jul-20257.2 KiB220140

event_latency_description.sqlD04-Jul-20259.9 KiB184176

graphics_pipeline.sqlD04-Jul-20254.5 KiB12672

histograms.sqlD04-Jul-20251.2 KiB4428

input.sqlD04-Jul-20254.9 KiB151105

interactions.sqlD04-Jul-20252.1 KiB6846

metadata.sqlD04-Jul-2025389 136

page_loads.sqlD04-Jul-20254.2 KiB11475

scroll_interactions.sqlD04-Jul-20251.9 KiB6748

speedometer.sqlD04-Jul-20253.2 KiB10568

speedometer_2_1.sqlD04-Jul-20257.3 KiB232181

speedometer_3.sqlD04-Jul-20256.6 KiB193151

startups.sqlD04-Jul-20252.9 KiB9977

tasks.sqlD04-Jul-202521.4 KiB647441

vsync_intervals.sqlD04-Jul-20251.8 KiB5731

web_content_interactions.sqlD04-Jul-20251.6 KiB4521

README

1# PerfettoSQL Chrome Standard Library
2
3The [PerfettoSQL Standard Library](https://perfetto.dev/docs/analysis/stdlib-docs) contains commonly used SQL tables, views, functions and macros to make it easier for users to query traces. The Chrome Standard Library contains those metrics that are specific to Chrome.
4
5The source of truth of the Perfetto SQL Chrome stdlib is the Chromium repository in `base/tracing/stdlib/` which makes it easier to develop new metrics and add tests for them in a single Chromium CL. So any changes to the Chrome stdlib should be made here.
6
7## Modifying the Chrome Stdlib
8
9You can add or modify a metric in `base/tracing/stdlib/chrome/`. If you add a new file here, you must add this to `perfetto_sql_files.gni` as well so it can be added to the source set.
10
11If you make changes to the chrome stdlib, you should add/modify a diff test too. You may also wish to add an end-to-end TestTraceProcessor unit/browser test. See [instructions](../../test/README) on how to add these tests.
12
13## PerfettoSQL Schema
14
15The Perfetto CI runs a [script](https://source.chromium.org/chromium/chromium/src/+/main:third_party/perfetto/tools/check_sql_modules.py) to check that standard library modules are documented with the proper schema. In Chromium, we can run these checks locally by running `tools/tracing/check_stdlib.py`. This is also run as a presubmit check, so you could also run `git cl presubmit` to run these after you've created a CL.