)]}'
{
  "commit": "020179010ef9b53ce4a5197229f80676b7e0a4d5",
  "tree": "7fc47cfee8fb8168f3e858dc5e177f9d789ed295",
  "parents": [
    "fb15418c3ccb380cfaf9220e7cdbfa1929289736"
  ],
  "author": {
    "name": "Aditya Gupta",
    "email": "adigupt@google.com",
    "time": "Mon Nov 09 16:44:00 2026 +0000"
  },
  "committer": {
    "name": "Aditya Gupta",
    "email": "adigupt@google.com",
    "time": "Mon Nov 09 16:44:00 2026 +0000"
  },
  "message": "tp: stdlib: let android.cujs consume CUJs with typed vsync args and no HWUI frames\n\nGeneralise the android.cujs stdlib so that a CUJ producer which cannot emit\nthe Android-framework style dynamic instant markers\n(`J\u003cX\u003e#FT#beginVsync#\u003cid\u003e`, `#FT#endVsync#\u003cid\u003e`, `#FT#end#0`, `#FT#cancel#0`)\nand which does not render through HWUI (no `Choreographer#doFrame`) can still\nbe analysed by android_jank_cuj and friends.\n\nThe first such producer is Chrome, which emits a `J\u003cWebContentsScroll\u003e`\nTrackEvent slice in its GPU process (the process that owns the SurfaceFlinger\nlayer) with `ChromeTrackEvent.android_cuj_metrics.{begin_vsync_id,\nend_vsync_id, canceled}` as typed args. Nothing in the stdlib is\nChrome-specific; any process emitting the same shape of data is handled\nidentically.\n\nChanges (all additive, existing paths unchanged):\n\n* base.sql\n  - New `_cuj_typed_args`: reads the three typed args from the CUJ slice.\n  - `_cuj_instant_events.begin_vsync/end_vsync`: `coalesce(typed arg, FT#\n    marker)` - typed args win when present, otherwise identical to before.\n  - New `_android_jank_cuj_state(cuj_id)`: typed `canceled` first, then the\n    existing FT#cancel / FT#end marker logic; replaces two inline copies.\n  - `android_jank_cuj_layer_name`: third, same-process fallback for CUJs\n    that carry explicit vsync bounds but have no HWUI frames: the\n    `actual_frame_timeline_slice` layer of the CUJ\u0027s own process that\n    presented at both bounds (most frames wins). CUJs resolved by the two\n    existing rules are never affected.\n\n* boundaries.sql\n  - `_android_jank_cuj_vsync_boundary`: include CUJs with `Choreographer#\n    doFrame`s (as before) OR with explicit vsync bounds and a resolved layer.\n    `upid` and the column set are unchanged.\n\n* frames.sql\n  - `android_jank_cuj_slice_summary.state` uses `_android_jank_cuj_state`.\n\n* protos/third_party/chromium/chrome_track_event.proto\n  - Mirror of crrev.com/c/8705993 (`AndroidCujMetrics`, field 1087).\n\nBehavioural impact: CUJs without typed args and with doFrames are\nbyte-identical (SystemUI and Gmail reference traces, all 50 existing CUJ/Jank\ndiff tests). A marker-only CUJ with explicit vsync markers and no HWUI frames\ncan now get a boundary/frames if one of its own layers spans the range.\n\nTests: new ChromeCujs diff-test suite with a synthetic trace (GPU-process\n`J\u003cWebContentsScroll\u003e` slices with typed args, one completed and one\ncanceled; distractor frames from the browser process and SystemUI).\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "31e3f6f8fe0c351bf6a340616ff083814f46affc",
      "old_mode": 33188,
      "old_path": "protos/third_party/chromium/chrome_track_event.proto",
      "new_id": "7468fefe76c7f49d76c1ef70f6b45778023c23c8",
      "new_mode": 33188,
      "new_path": "protos/third_party/chromium/chrome_track_event.proto"
    },
    {
      "type": "modify",
      "old_id": "d76f866d662f40ef78dfa81a009eec671f62327c",
      "old_mode": 33188,
      "old_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/base.sql",
      "new_id": "0fc29cfc0a75a572bdd858689b493284deedf593",
      "new_mode": 33188,
      "new_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/base.sql"
    },
    {
      "type": "modify",
      "old_id": "947a0f519d401d4fcaff8c74b37ae72d4e0ce2d6",
      "old_mode": 33188,
      "old_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/boundaries.sql",
      "new_id": "fcbc09afdc4c4efd53d018033d3f7f5f1691cf7d",
      "new_mode": 33188,
      "new_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/boundaries.sql"
    },
    {
      "type": "modify",
      "old_id": "e0ed4409cf3d305fc999334dca0f8585840a7cad",
      "old_mode": 33188,
      "old_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/frames.sql",
      "new_id": "7cd440565ad06ead55f93f84d4c2c58f2a3371be",
      "new_mode": 33188,
      "new_path": "src/trace_processor/perfetto_sql/stdlib/android/cujs/frames.sql"
    },
    {
      "type": "modify",
      "old_id": "f9aa4476c119bb3380787d87ff8f19912bc7fb23",
      "old_mode": 33188,
      "old_path": "test/trace_processor/diff_tests/include_index.py",
      "new_id": "b39a9890599d6530af17374f873c38ab2f6d2e68",
      "new_mode": 33188,
      "new_path": "test/trace_processor/diff_tests/include_index.py"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "30a352e10e193402878f257b6789f5f4f021be73",
      "new_mode": 33188,
      "new_path": "test/trace_processor/diff_tests/stdlib/android/chrome_cujs_tests.py"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "402c5f25393b0b9d5b67085e14212d2e2010fc7d",
      "new_mode": 33188,
      "new_path": "test/trace_processor/diff_tests/stdlib/android/chrome_web_contents_scroll_cuj.py"
    }
  ]
}
