[tracing] Migrate TraceLog observers to TraceSessionObserverList [chromium/src : main]

0 views
Skip to first unread message

Etienne Pierre-Doray (Gerrit)

unread,
Dec 10, 2025, 3:35:51 PM (10 days ago) Dec 10
to Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
Attention needed from Mikhail Khokhlov

Etienne Pierre-Doray added 1 comment

Patchset-level comments
File-level comment, Patchset 16 (Latest):
Etienne Pierre-Doray . resolved

PTAL

Open in Gerrit

Related details

Attention is currently required from:
  • Mikhail Khokhlov
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
Gerrit-Change-Number: 7234082
Gerrit-PatchSet: 16
Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
Gerrit-Attention: Mikhail Khokhlov <khok...@google.com>
Gerrit-Comment-Date: Wed, 10 Dec 2025 20:35:45 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Mikhail Khokhlov (Gerrit)

unread,
Dec 11, 2025, 7:52:50 AM (10 days ago) Dec 11
to Etienne Pierre-Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
Attention needed from Etienne Pierre-Doray

Mikhail Khokhlov added 3 comments

File chrome/browser/metrics/pressure/pressure_metrics_reporter.cc
Line 98, Patchset 16 (Latest): if (sessions_after == 0 && tracing_sampling_timer_.IsRunning()) {
Mikhail Khokhlov . unresolved

This can continue tracing for longer than intended (e.g. a long-running trace session starts, then a short one with kTraceCategoryForPressureEvents starts and stops; sampling will continue until the end of the long-running session).

Should we plumb the session id to observers to correctly track which session stopped?

File content/renderer/render_thread_impl.cc
Line 703, Patchset 16 (Latest):void RenderThreadImpl::OnTraceSessionStart(size_t sessions_before) {
Mikhail Khokhlov . unresolved

This will now emit extra events in the case of multiple sessions. Is this intentional?

File third_party/blink/renderer/core/scheduler/task_attribution_tracker_impl.cc
Line 240, Patchset 16 (Latest): if (sessions_after == 0) {
Mikhail Khokhlov . unresolved

ditto, this can trace past the end of the intended session.

Open in Gerrit

Related details

Attention is currently required from:
  • Etienne Pierre-Doray
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
    Gerrit-Change-Number: 7234082
    Gerrit-PatchSet: 16
    Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
    Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
    Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
    Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Dec 2025 12:52:32 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Etienne Pierre-Doray (Gerrit)

    unread,
    Dec 12, 2025, 11:43:42 AM (8 days ago) Dec 12
    to Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
    Attention needed from Mikhail Khokhlov

    Etienne Pierre-Doray added 4 comments

    Patchset-level comments
    File-level comment, Patchset 18 (Latest):
    Etienne Pierre-Doray . resolved

    PTAnL?

    File chrome/browser/metrics/pressure/pressure_metrics_reporter.cc
    Line 98, Patchset 16: if (sessions_after == 0 && tracing_sampling_timer_.IsRunning()) {
    Mikhail Khokhlov . resolved

    This can continue tracing for longer than intended (e.g. a long-running trace session starts, then a short one with kTraceCategoryForPressureEvents starts and stops; sampling will continue until the end of the long-running session).

    Should we plumb the session id to observers to correctly track which session stopped?

    Etienne Pierre-Doray

    Discussed in chat, I implemented a "lazy" stop that checks the category in the timer.
    I'm also exposing category API in perfetto so we can do proper tracking if needed: https://github.com/google/perfetto/pull/4106

    File content/renderer/render_thread_impl.cc
    Line 703, Patchset 16:void RenderThreadImpl::OnTraceSessionStart(size_t sessions_before) {
    Mikhail Khokhlov . resolved

    This will now emit extra events in the case of multiple sessions. Is this intentional?

    Etienne Pierre-Doray

    Actually I realize those should go away, I removed the updates here: https://chromium-review.googlesource.com/c/chromium/src/+/7147741
    Because they are redundant, but forgot to remove the observer.

    But in general yes, I think it's better to "restart" async events (given they don't nest) than missing them in a new tracing session.

    File third_party/blink/renderer/core/scheduler/task_attribution_tracker_impl.cc
    Line 240, Patchset 16: if (sessions_after == 0) {
    Mikhail Khokhlov . resolved

    ditto, this can trace past the end of the intended session.

    Etienne Pierre-Doray

    In this case I'm optimistically removing the hook, this should be no worse than the status-quo.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Mikhail Khokhlov
    Submit Requirements:
      • requirement satisfiedCode-Coverage
      • requirement is not satisfiedCode-Owners
      • requirement is not satisfiedCode-Review
      • requirement is not satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: chromium/src
      Gerrit-Branch: main
      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
      Gerrit-Change-Number: 7234082
      Gerrit-PatchSet: 18
      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
      Gerrit-Attention: Mikhail Khokhlov <khok...@google.com>
      Gerrit-Comment-Date: Fri, 12 Dec 2025 16:43:35 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      Comment-In-Reply-To: Mikhail Khokhlov <khok...@google.com>
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Mikhail Khokhlov (Gerrit)

      unread,
      Dec 12, 2025, 11:50:40 AM (8 days ago) Dec 12
      to Etienne Pierre-Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
      Attention needed from Etienne Pierre-Doray

      Mikhail Khokhlov voted and added 1 comment

      Votes added by Mikhail Khokhlov

      Code-Review+1

      1 comment

      Patchset-level comments
      File-level comment, Patchset 19 (Latest):
      Mikhail Khokhlov . resolved

      Thanks!

      Open in Gerrit

      Related details

      Attention is currently required from:
      • Etienne Pierre-Doray
      Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement is not satisfiedCode-Owners
        • requirement satisfiedCode-Review
        • requirement satisfiedReview-Enforcement
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
        Gerrit-Change-Number: 7234082
        Gerrit-PatchSet: 19
        Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
        Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Comment-Date: Fri, 12 Dec 2025 16:50:22 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Etienne Pierre-Doray (Gerrit)

        unread,
        Dec 12, 2025, 11:53:01 AM (8 days ago) Dec 12
        to Dave Tapuska, Francois Pierre Doray, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
        Attention needed from Dave Tapuska and Francois Pierre Doray

        Etienne Pierre-Doray added 1 comment

        Patchset-level comments
        Etienne Pierre-Doray . resolved

        +dtapuska@ for content/ and t_p/blink/renderer
        +fdoray@ for c/b/metrics

        Open in Gerrit

        Related details

        Attention is currently required from:
        • Dave Tapuska
        • Francois Pierre Doray
        Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement is not satisfiedCode-Owners
        • requirement satisfiedCode-Review
        • requirement satisfiedReview-Enforcement
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
        Gerrit-Change-Number: 7234082
        Gerrit-PatchSet: 19
        Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Dave Tapuska <dtap...@chromium.org>
        Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
        Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
        Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
        Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
        Gerrit-Comment-Date: Fri, 12 Dec 2025 16:52:54 +0000
        Gerrit-HasComments: Yes
        Gerrit-Has-Labels: No
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Francois Pierre Doray (Gerrit)

        unread,
        Dec 12, 2025, 12:02:41 PM (8 days ago) Dec 12
        to Etienne Pierre-Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
        Attention needed from Dave Tapuska and Etienne Pierre-Doray

        Francois Pierre Doray voted Code-Review+1

        Code-Review+1
        Open in Gerrit

        Related details

        Attention is currently required from:
        • Dave Tapuska
        • Etienne Pierre-Doray
        Submit Requirements:
        • requirement satisfiedCode-Coverage
        • requirement is not satisfiedCode-Owners
        • requirement satisfiedCode-Review
        • requirement satisfiedReview-Enforcement
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: chromium/src
        Gerrit-Branch: main
        Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
        Gerrit-Change-Number: 7234082
        Gerrit-PatchSet: 19
        Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Dave Tapuska <dtap...@chromium.org>
        Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
        Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
        Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
        Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
        Gerrit-Comment-Date: Fri, 12 Dec 2025 17:01:57 +0000
        Gerrit-HasComments: No
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy

        Dave Tapuska (Gerrit)

        unread,
        Dec 12, 2025, 12:15:30 PM (8 days ago) Dec 12
        to Etienne Pierre-Doray, Francois Pierre Doray, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
        Attention needed from Etienne Pierre-Doray

        Dave Tapuska added 1 comment

        File content/app/content_main.cc
        Line 172, Patchset 19 (Latest): ++active_track_event_sessions_;
        Dave Tapuska . unresolved

        So could tracing be enabled before this observer is added? And cause active_trace_event_sessions_ to become negative?

        It does not appear that OnStart is called if tracing is active when the listener is added (perhaps I missed it).

        Open in Gerrit

        Related details

        Attention is currently required from:
        • Etienne Pierre-Doray
        Submit Requirements:
          • requirement satisfiedCode-Coverage
          • requirement is not satisfiedCode-Owners
          • requirement satisfiedCode-Review
          • requirement is not satisfiedNo-Unresolved-Comments
          • requirement satisfiedReview-Enforcement
          Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
          Gerrit-MessageType: comment
          Gerrit-Project: chromium/src
          Gerrit-Branch: main
          Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
          Gerrit-Change-Number: 7234082
          Gerrit-PatchSet: 19
          Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
          Gerrit-Reviewer: Dave Tapuska <dtap...@chromium.org>
          Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
          Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
          Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
          Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
          Gerrit-Comment-Date: Fri, 12 Dec 2025 17:15:21 +0000
          Gerrit-HasComments: Yes
          Gerrit-Has-Labels: No
          satisfied_requirement
          unsatisfied_requirement
          open
          diffy

          Etienne Pierre-Doray (Gerrit)

          unread,
          Dec 15, 2025, 11:51:27 AM (5 days ago) Dec 15
          to Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
          Attention needed from Dave Tapuska, Francois Pierre Doray and Mikhail Khokhlov

          Etienne Pierre-Doray added 2 comments

          Patchset-level comments
          File-level comment, Patchset 21 (Latest):
          Etienne Pierre-Doray . resolved

          PTAnL

          File content/app/content_main.cc
          Line 172, Patchset 19: ++active_track_event_sessions_;
          Dave Tapuska . resolved

          So could tracing be enabled before this observer is added? And cause active_trace_event_sessions_ to become negative?

          It does not appear that OnStart is called if tracing is active when the listener is added (perhaps I missed it).

          Etienne Pierre-Doray

          Good catch, I went with a different approach, instead of counting instance, I'm querying the state directly, accounting for OnStop instance with a helper.

          Open in Gerrit

          Related details

          Attention is currently required from:
          • Dave Tapuska
          • Francois Pierre Doray
          • Mikhail Khokhlov
          Submit Requirements:
            • requirement satisfiedCode-Coverage
            • requirement is not satisfiedCode-Owners
            • requirement is not satisfiedCode-Review
            • requirement is not satisfiedReview-Enforcement
            Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
            Gerrit-MessageType: comment
            Gerrit-Project: chromium/src
            Gerrit-Branch: main
            Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
            Gerrit-Change-Number: 7234082
            Gerrit-PatchSet: 21
            Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
            Gerrit-Reviewer: Dave Tapuska <dtap...@chromium.org>
            Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
            Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
            Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
            Gerrit-Attention: Mikhail Khokhlov <khok...@google.com>
            Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
            Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
            Gerrit-Comment-Date: Mon, 15 Dec 2025 16:51:22 +0000
            Gerrit-HasComments: Yes
            Gerrit-Has-Labels: No
            Comment-In-Reply-To: Dave Tapuska <dtap...@chromium.org>
            satisfied_requirement
            unsatisfied_requirement
            open
            diffy

            Mikhail Khokhlov (Gerrit)

            unread,
            Dec 15, 2025, 12:52:26 PM (5 days ago) Dec 15
            to Etienne Pierre-Doray, Francois Pierre Doray, Dave Tapuska, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
            Attention needed from Dave Tapuska, Etienne Pierre-Doray and Francois Pierre Doray

            Mikhail Khokhlov voted and added 4 comments

            Votes added by Mikhail Khokhlov

            Code-Review+1

            4 comments

            Patchset-level comments
            File-level comment, Patchset 22 (Latest):
            Mikhail Khokhlov . resolved

            LGTM w/nits

            File base/trace_event/trace_session_observer.cc
            Line 15, Patchset 21: StopArgsImpl(const perfetto::DataSourceBase::StopArgs& args)
            Mikhail Khokhlov . unresolved

            Please fix this WARNING reported by ClangTidy: check: google-explicit-constructor

            single-argument constructors must be marked ...

            check: google-explicit-constructor

            single-argument constructors must be marked explicit to avoid unintentional implicit conversions (https://clang.llvm.org/extra/clang-tidy/checks/google/explicit-constructor.html)

            (Note: You can add `Skip-Clang-Tidy-Checks: google-explicit-constructor` footer to the CL description to skip the check)

            (Lint observed on `android-clang-tidy-rel`, but not on `linux-clang-tidy-rel`)

            Line 26, Patchset 22 (Latest):bool IsEnabledOnStop(uint32_t instances,
            Mikhail Khokhlov . unresolved

            Naming suggestion: `IsEnabledByInstance`?

            File net/log/trace_net_log_observer.cc
            Line 345, Patchset 22 (Latest): bool enabled = false;
            Mikhail Khokhlov . unresolved

            Naming suggestion: `bool should_stop = true;`

            Open in Gerrit

            Related details

            Attention is currently required from:
            • Dave Tapuska
            • Etienne Pierre-Doray
            • Francois Pierre Doray
              Submit Requirements:
                • requirement satisfiedCode-Coverage
                • requirement is not satisfiedCode-Owners
                • requirement satisfiedCode-Review
                • requirement is not satisfiedNo-Unresolved-Comments
                • requirement satisfiedReview-Enforcement
                Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                Gerrit-MessageType: comment
                Gerrit-Project: chromium/src
                Gerrit-Branch: main
                Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                Gerrit-Change-Number: 7234082
                Gerrit-PatchSet: 22
                Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Dave Tapuska <dtap...@chromium.org>
                Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Comment-Date: Mon, 15 Dec 2025 17:52:06 +0000
                Gerrit-HasComments: Yes
                Gerrit-Has-Labels: Yes
                satisfied_requirement
                unsatisfied_requirement
                open
                diffy

                Etienne Pierre-Doray (Gerrit)

                unread,
                Dec 15, 2025, 1:05:23 PM (5 days ago) Dec 15
                to Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Francois Pierre Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                Attention needed from Dave Tapuska, Dmitry Gozman, Francois Pierre Doray and Mikhail Khokhlov

                Etienne Pierre-Doray added 4 comments

                Patchset-level comments
                File-level comment, Patchset 24 (Latest):
                Etienne Pierre-Doray . resolved

                dtapuska is OOO -> +dgozman@ for content/ and t_p/b/renderer

                File base/trace_event/trace_session_observer.cc
                Line 15, Patchset 21: StopArgsImpl(const perfetto::DataSourceBase::StopArgs& args)
                Mikhail Khokhlov . resolved

                Please fix this WARNING reported by ClangTidy: check: google-explicit-constructor

                single-argument constructors must be marked ...

                check: google-explicit-constructor

                single-argument constructors must be marked explicit to avoid unintentional implicit conversions (https://clang.llvm.org/extra/clang-tidy/checks/google/explicit-constructor.html)

                (Note: You can add `Skip-Clang-Tidy-Checks: google-explicit-constructor` footer to the CL description to skip the check)

                (Lint observed on `android-clang-tidy-rel`, but not on `linux-clang-tidy-rel`)

                Etienne Pierre-Doray

                Done

                Line 26, Patchset 22:bool IsEnabledOnStop(uint32_t instances,
                Mikhail Khokhlov . unresolved

                Naming suggestion: `IsEnabledByInstance`?

                Etienne Pierre-Doray

                Not sure this is accurate: the function returns true if any instance is enabled, whereas IsEnabledByInstance() sounds like it returns the state only for a specific instance.
                I updated the comment though.

                File net/log/trace_net_log_observer.cc
                Line 345, Patchset 22: bool enabled = false;
                Mikhail Khokhlov . resolved

                Naming suggestion: `bool should_stop = true;`

                Etienne Pierre-Doray

                Done

                Open in Gerrit

                Related details

                Attention is currently required from:
                • Dave Tapuska
                • Dmitry Gozman
                • Francois Pierre Doray
                • Mikhail Khokhlov
                Submit Requirements:
                • requirement satisfiedCode-Coverage
                • requirement is not satisfiedCode-Owners
                • requirement satisfiedCode-Review
                • requirement is not satisfiedNo-Unresolved-Comments
                • requirement satisfiedReview-Enforcement
                Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                Gerrit-MessageType: comment
                Gerrit-Project: chromium/src
                Gerrit-Branch: main
                Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                Gerrit-Change-Number: 7234082
                Gerrit-PatchSet: 24
                Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                Gerrit-Attention: Mikhail Khokhlov <khok...@google.com>
                Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Comment-Date: Mon, 15 Dec 2025 18:05:14 +0000
                Gerrit-HasComments: Yes
                Gerrit-Has-Labels: No
                Comment-In-Reply-To: Mikhail Khokhlov <khok...@google.com>
                satisfied_requirement
                unsatisfied_requirement
                open
                diffy

                Etienne Pierre-Doray (Gerrit)

                unread,
                Dec 15, 2025, 3:21:18 PM (5 days ago) Dec 15
                to Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Francois Pierre Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                Attention needed from Dave Tapuska, Dmitry Gozman, Francois Pierre Doray, Mikhail Khokhlov and mmenke

                Etienne Pierre-Doray added 1 comment

                Patchset-level comments
                File-level comment, Patchset 25 (Latest):
                Etienne Pierre-Doray . resolved

                +mmenke@ for net/log

                Open in Gerrit

                Related details

                Attention is currently required from:
                • Dave Tapuska
                • Dmitry Gozman
                • Francois Pierre Doray
                • Mikhail Khokhlov
                • mmenke
                Submit Requirements:
                • requirement satisfiedCode-Coverage
                • requirement is not satisfiedCode-Owners
                • requirement satisfiedCode-Review
                • requirement is not satisfiedNo-Unresolved-Comments
                • requirement satisfiedReview-Enforcement
                Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                Gerrit-MessageType: comment
                Gerrit-Project: chromium/src
                Gerrit-Branch: main
                Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                Gerrit-Change-Number: 7234082
                Gerrit-PatchSet: 25
                Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                Gerrit-Reviewer: mmenke <mme...@chromium.org>
                Gerrit-Attention: mmenke <mme...@chromium.org>
                Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                Gerrit-Attention: Mikhail Khokhlov <khok...@google.com>
                Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
                Gerrit-Comment-Date: Mon, 15 Dec 2025 20:21:09 +0000
                Gerrit-HasComments: Yes
                Gerrit-Has-Labels: No
                satisfied_requirement
                unsatisfied_requirement
                open
                diffy

                Mikhail Khokhlov (Gerrit)

                unread,
                Dec 16, 2025, 5:42:42 AM (5 days ago) Dec 16
                to Etienne Pierre-Doray, Dmitry Gozman, Dave Tapuska, Francois Pierre Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                Attention needed from Dave Tapuska, Dmitry Gozman, Etienne Pierre-Doray, Francois Pierre Doray and mmenke

                Mikhail Khokhlov voted and added 1 comment

                Votes added by Mikhail Khokhlov

                Code-Review+1

                1 comment

                File base/trace_event/trace_session_observer.cc
                Line 26, Patchset 22:bool IsEnabledOnStop(uint32_t instances,
                Mikhail Khokhlov . resolved

                Naming suggestion: `IsEnabledByInstance`?

                Etienne Pierre-Doray

                Not sure this is accurate: the function returns true if any instance is enabled, whereas IsEnabledByInstance() sounds like it returns the state only for a specific instance.
                I updated the comment though.

                Mikhail Khokhlov

                Acknowledged

                Open in Gerrit

                Related details

                Attention is currently required from:
                • Dave Tapuska
                • Dmitry Gozman
                • Etienne Pierre-Doray
                • Francois Pierre Doray
                • mmenke
                Submit Requirements:
                  • requirement satisfiedCode-Coverage
                  • requirement is not satisfiedCode-Owners
                  • requirement satisfiedCode-Review
                  • requirement satisfiedReview-Enforcement
                  Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                  Gerrit-MessageType: comment
                  Gerrit-Project: chromium/src
                  Gerrit-Branch: main
                  Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                  Gerrit-Change-Number: 7234082
                  Gerrit-PatchSet: 25
                  Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                  Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                  Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                  Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                  Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                  Gerrit-Reviewer: mmenke <mme...@chromium.org>
                  Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                  Gerrit-Attention: mmenke <mme...@chromium.org>
                  Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                  Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                  Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                  Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
                  Gerrit-Comment-Date: Tue, 16 Dec 2025 10:42:25 +0000
                  Gerrit-HasComments: Yes
                  Gerrit-Has-Labels: Yes
                  Comment-In-Reply-To: Mikhail Khokhlov <khok...@google.com>
                  Comment-In-Reply-To: Etienne Pierre-Doray <etie...@chromium.org>
                  satisfied_requirement
                  unsatisfied_requirement
                  open
                  diffy

                  mmenke (Gerrit)

                  unread,
                  Dec 16, 2025, 11:08:58 AM (4 days ago) Dec 16
                  to Etienne Pierre-Doray, Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Francois Pierre Doray, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                  Attention needed from Dave Tapuska, Dmitry Gozman, Etienne Pierre-Doray and Francois Pierre Doray

                  mmenke added 5 comments

                  Commit Message
                  Line 7, Patchset 25 (Latest):[tracing] Migrate TraceLog observers to TraceSessionObserverList
                  mmenke . unresolved

                  This is confusing. Observers may be using `TraceEventSessionObserverList`, but they're becoming `TrackEventSessionObservers` (with a k). There should be some mention of this here.

                  File net/log/trace_net_log_observer.h
                  Line 71, Patchset 25 (Latest): void OnStart(const perfetto::DataSourceBase::StartArgs&) override;
                  mmenke . unresolved

                  This API seems underspecified. I'm not sure what a "track event tracing session" is. Do these arguments represent an accumulation of global state, or more local state?

                  Line 24, Patchset 25 (Latest): public perfetto::TrackEventSessionObserver {
                  mmenke . unresolved

                  I'm confused by the CL description. It mentions migrating to TraceEventSessionObserver, but this is a TrackEventSessionObserver.

                  File net/log/trace_net_log_observer.cc
                  Line 349, Patchset 25 (Latest): should_stop = !base::trace_event::IsEnabledOnStop(instances, args);
                  mmenke . unresolved

                  So args are per-"trac[e|k] session", of which there can be more than one, while we need to apply that as a delta to the global tracing state (which I guess tracks number of active sessions, because OnStop is called before the global tracing state is updated).

                  This API seems incredibly clunky here. Is there a better way to be using it?

                  Line 351, Patchset 25 (Latest): if (should_stop && net_log()) {
                  mmenke . unresolved

                  We should probably just early return if !net_log()? Admittedly, perf doesn't matter here, it just seems weird to do the extra work before checking the class's own state.

                  Open in Gerrit

                  Related details

                  Attention is currently required from:
                  • Dave Tapuska
                  • Dmitry Gozman
                  • Etienne Pierre-Doray
                  • Francois Pierre Doray
                  Submit Requirements:
                    • requirement satisfiedCode-Coverage
                    • requirement is not satisfiedCode-Owners
                    • requirement satisfiedCode-Review
                    • requirement is not satisfiedNo-Unresolved-Comments
                    • requirement satisfiedReview-Enforcement
                    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                    Gerrit-MessageType: comment
                    Gerrit-Project: chromium/src
                    Gerrit-Branch: main
                    Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                    Gerrit-Change-Number: 7234082
                    Gerrit-PatchSet: 25
                    Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                    Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                    Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                    Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                    Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                    Gerrit-Reviewer: mmenke <mme...@chromium.org>
                    Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                    Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                    Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                    Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                    Gerrit-Attention: Francois Pierre Doray <fdo...@chromium.org>
                    Gerrit-Comment-Date: Tue, 16 Dec 2025 16:08:34 +0000
                    Gerrit-HasComments: Yes
                    Gerrit-Has-Labels: No
                    satisfied_requirement
                    unsatisfied_requirement
                    open
                    diffy

                    Francois Pierre Doray (Gerrit)

                    unread,
                    Dec 16, 2025, 11:52:10 AM (4 days ago) Dec 16
                    to Etienne Pierre-Doray, Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                    Attention needed from Dave Tapuska, Dmitry Gozman and Etienne Pierre-Doray

                    Francois Pierre Doray voted Code-Review+1

                    Code-Review+1
                    Open in Gerrit

                    Related details

                    Attention is currently required from:
                    • Dave Tapuska
                    • Dmitry Gozman
                    • Etienne Pierre-Doray
                    Gerrit-Comment-Date: Tue, 16 Dec 2025 16:52:01 +0000
                    Gerrit-HasComments: No
                    Gerrit-Has-Labels: Yes
                    satisfied_requirement
                    unsatisfied_requirement
                    open
                    diffy

                    Etienne Pierre-Doray (Gerrit)

                    unread,
                    Dec 16, 2025, 1:27:10 PM (4 days ago) Dec 16
                    to Francois Pierre Doray, Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                    Attention needed from Dave Tapuska, Dmitry Gozman and mmenke

                    Etienne Pierre-Doray added 5 comments

                    Commit Message
                    Line 7, Patchset 25:[tracing] Migrate TraceLog observers to TraceSessionObserverList
                    mmenke . resolved

                    This is confusing. Observers may be using `TraceEventSessionObserverList`, but they're becoming `TrackEventSessionObservers` (with a k). There should be some mention of this here.

                    Etienne Pierre-Doray

                    For all intents and purposes, in Chrome TraceSession == TrackEventSession (TrackEvent is a data source that generates TRACE_EVENT data), that's because there's very little tracing that's not using TRACE_EVENT.

                    So the main thing this CL does is change TraceLog observers to a per-session observers.
                    For simplicity, I'm keeping TraceEventSessionObserver naming (I made the CL more consistent now).

                    File net/log/trace_net_log_observer.h
                    Line 71, Patchset 25: void OnStart(const perfetto::DataSourceBase::StartArgs&) override;
                    mmenke . resolved

                    This API seems underspecified. I'm not sure what a "track event tracing session" is. Do these arguments represent an accumulation of global state, or more local state?

                    Line 24, Patchset 25: public perfetto::TrackEventSessionObserver {
                    mmenke . resolved

                    I'm confused by the CL description. It mentions migrating to TraceEventSessionObserver, but this is a TrackEventSessionObserver.

                    Etienne Pierre-Doray

                    Fixed.

                    File net/log/trace_net_log_observer.cc
                    Line 349, Patchset 25: should_stop = !base::trace_event::IsEnabledOnStop(instances, args);
                    mmenke . unresolved

                    So args are per-"trac[e|k] session", of which there can be more than one, while we need to apply that as a delta to the global tracing state (which I guess tracks number of active sessions, because OnStop is called before the global tracing state is updated).

                    This API seems incredibly clunky here. Is there a better way to be using it?

                    Etienne Pierre-Doray

                    I improved the ergonomics a bit, now simply IsCategoryEnabledOnStop().

                    This API seems incredibly clunky here. Is there a better way to be using it?

                    It's a bit convoluted, I wanted to fix this in perfetto, but got push back
                    https://github.com/google/perfetto/pull/4096#issuecomment-3646238607

                    I also don't really want to make a "trace category" observer a first class citizen yet, because of the extra implementation complexity and similar use cases were better served by creating a custom data source
                    https://perfetto.dev/docs/instrumentation/tracing-sdk#custom-data-sources

                    Overall I wanted to prioritize the more common use case that emits state in OnStart(), and the less common "data source like" use case like this one (there's only 2 in chrome and 1 in v8) is retrofit in the same observer interface.

                    Line 351, Patchset 25: if (should_stop && net_log()) {
                    mmenke . resolved

                    We should probably just early return if !net_log()? Admittedly, perf doesn't matter here, it just seems weird to do the extra work before checking the class's own state.

                    Etienne Pierre-Doray

                    Done

                    Open in Gerrit

                    Related details

                    Attention is currently required from:
                    • Dave Tapuska
                    • Dmitry Gozman
                    • mmenke
                    Submit Requirements:
                    • requirement satisfiedCode-Coverage
                    • requirement is not satisfiedCode-Owners
                    • requirement satisfiedCode-Review
                    • requirement is not satisfiedNo-Unresolved-Comments
                    • requirement satisfiedReview-Enforcement
                    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                    Gerrit-MessageType: comment
                    Gerrit-Project: chromium/src
                    Gerrit-Branch: main
                    Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                    Gerrit-Change-Number: 7234082
                    Gerrit-PatchSet: 28
                    Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                    Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                    Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                    Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                    Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                    Gerrit-Reviewer: mmenke <mme...@chromium.org>
                    Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                    Gerrit-Attention: mmenke <mme...@chromium.org>
                    Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                    Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                    Gerrit-Comment-Date: Tue, 16 Dec 2025 18:27:00 +0000
                    Gerrit-HasComments: Yes
                    Gerrit-Has-Labels: No
                    Comment-In-Reply-To: mmenke <mme...@chromium.org>
                    satisfied_requirement
                    unsatisfied_requirement
                    open
                    diffy

                    mmenke (Gerrit)

                    unread,
                    Dec 16, 2025, 1:42:18 PM (4 days ago) Dec 16
                    to Etienne Pierre-Doray, Francois Pierre Doray, Dmitry Gozman, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                    Attention needed from Dave Tapuska, Dmitry Gozman and Etienne Pierre-Doray

                    mmenke voted and added 3 comments

                    Votes added by mmenke

                    Code-Review+1

                    3 comments

                    Patchset-level comments
                    File net/log/trace_net_log_observer.h
                    Line 71, Patchset 25: void OnStart(const perfetto::DataSourceBase::StartArgs&) override;
                    mmenke . resolved

                    This API seems underspecified. I'm not sure what a "track event tracing session" is. Do these arguments represent an accumulation of global state, or more local state?

                    Etienne Pierre-Doray

                    I added documentation in trace_session_observer.h
                    But the individual arguments are documented here: https://source.chromium.org/chromium/chromium/src/+/main:third_party/perfetto/include/perfetto/tracing/internal/track_event_internal.h;l=69?q=perfetto::TrackEventSessionObserver&ss=chromium

                    mmenke

                    I saw that, but I don't know what a "track event tracing session" is. It could be e.g., a single consumer of trace events, or it could be a global singleton involving all consumers of trace events. I guess it's the former.

                    File net/log/trace_net_log_observer.cc
                    Line 349, Patchset 25: should_stop = !base::trace_event::IsEnabledOnStop(instances, args);
                    mmenke . resolved

                    So args are per-"trac[e|k] session", of which there can be more than one, while we need to apply that as a delta to the global tracing state (which I guess tracks number of active sessions, because OnStop is called before the global tracing state is updated).

                    This API seems incredibly clunky here. Is there a better way to be using it?

                    Etienne Pierre-Doray

                    I improved the ergonomics a bit, now simply IsCategoryEnabledOnStop().

                    This API seems incredibly clunky here. Is there a better way to be using it?

                    It's a bit convoluted, I wanted to fix this in perfetto, but got push back
                    https://github.com/google/perfetto/pull/4096#issuecomment-3646238607

                    I also don't really want to make a "trace category" observer a first class citizen yet, because of the extra implementation complexity and similar use cases were better served by creating a custom data source
                    https://perfetto.dev/docs/instrumentation/tracing-sdk#custom-data-sources

                    Overall I wanted to prioritize the more common use case that emits state in OnStart(), and the less common "data source like" use case like this one (there's only 2 in chrome and 1 in v8) is retrofit in the same observer interface.

                    mmenke

                    Acknowledged

                    Open in Gerrit

                    Related details

                    Attention is currently required from:
                    • Dave Tapuska
                    • Dmitry Gozman
                    • Etienne Pierre-Doray
                    Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Attention: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Tue, 16 Dec 2025 18:42:08 +0000
                      Gerrit-HasComments: Yes
                      Gerrit-Has-Labels: Yes
                      Comment-In-Reply-To: mmenke <mme...@chromium.org>
                      Comment-In-Reply-To: Etienne Pierre-Doray <etie...@chromium.org>
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      Dmitry Gozman (Gerrit)

                      unread,
                      Dec 17, 2025, 4:55:51 AM (4 days ago) Dec 17
                      to Etienne Pierre-Doray, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Dave Tapuska and Etienne Pierre-Doray

                      Dmitry Gozman added 1 comment

                      Patchset-level comments
                      Dmitry Gozman . resolved

                      Sorry, I am OOO until January. Moving myself from reviewers to cc.

                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Dave Tapuska
                      • Etienne Pierre-Doray
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-CC: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Wed, 17 Dec 2025 09:55:38 +0000
                      Gerrit-HasComments: Yes
                      Gerrit-Has-Labels: No
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      Etienne Pierre-Doray (Gerrit)

                      unread,
                      Dec 17, 2025, 4:49:22 PM (3 days ago) Dec 17
                      to Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Dave Tapuska and Kentaro Hara

                      Etienne Pierre-Doray added 1 comment

                      Patchset-level comments
                      Etienne Pierre-Doray . resolved

                      +haraken@ for t_p/blink

                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Dave Tapuska
                      • Kentaro Hara
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Kentaro Hara <har...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-CC: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Attention: Kentaro Hara <har...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Wed, 17 Dec 2025 21:49:11 +0000
                      Gerrit-HasComments: Yes
                      Gerrit-Has-Labels: No
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      Kentaro Hara (Gerrit)

                      unread,
                      Dec 17, 2025, 6:04:01 PM (3 days ago) Dec 17
                      to Etienne Pierre-Doray, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Dave Tapuska and Etienne Pierre-Doray

                      Kentaro Hara voted Code-Review+1

                      Code-Review+1
                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Dave Tapuska
                      • Etienne Pierre-Doray
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Kentaro Hara <har...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-CC: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Wed, 17 Dec 2025 23:03:21 +0000
                      Gerrit-HasComments: No
                      Gerrit-Has-Labels: Yes
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      Etienne Pierre-Doray (Gerrit)

                      unread,
                      Dec 17, 2025, 6:08:59 PM (3 days ago) Dec 17
                      to Chromium Metrics Reviews, Avi Drissman, Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Avi Drissman and Dave Tapuska

                      Etienne Pierre-Doray added 1 comment

                      Patchset-level comments
                      Etienne Pierre-Doray . resolved

                      +chromium-metrics-reviews@ for c/b/metrics
                      +a...@chromium.org for content/app

                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Avi Drissman
                      • Dave Tapuska
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
                      Gerrit-Reviewer: Chromium Metrics Reviews <chromium-met...@google.com>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Kentaro Hara <har...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-CC: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-Attention: Avi Drissman <a...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Wed, 17 Dec 2025 23:08:49 +0000
                      Gerrit-HasComments: Yes
                      Gerrit-Has-Labels: No
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      gwsq (Gerrit)

                      unread,
                      Dec 17, 2025, 6:14:07 PM (3 days ago) Dec 17
                      to Etienne Pierre-Doray, Chromium Metrics Reviews, Robert Kaplow, Avi Drissman, Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Avi Drissman, Dave Tapuska and Robert Kaplow

                      Message from gwsq

                      Reviewer source(s):
                      rka...@chromium.org is from context(analysis/uma/chrome-metrics.gwsq)

                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Avi Drissman
                      • Dave Tapuska
                      • Robert Kaplow
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement is not satisfiedCode-Owners
                      • requirement satisfiedCode-Review
                      • requirement satisfiedReview-Enforcement
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: comment
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 28
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Kentaro Hara <har...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: Robert Kaplow <rka...@chromium.org>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      Gerrit-CC: Chromium Metrics Reviews <chromium-met...@google.com>
                      Gerrit-CC: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-CC: Dmitry Gozman <dgo...@chromium.org>
                      Gerrit-CC: gwsq
                      Gerrit-Attention: Robert Kaplow <rka...@chromium.org>
                      Gerrit-Attention: Avi Drissman <a...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Wed, 17 Dec 2025 23:13:52 +0000
                      Gerrit-HasComments: No
                      Gerrit-Has-Labels: No
                      satisfied_requirement
                      unsatisfied_requirement
                      open
                      diffy

                      Avi Drissman (Gerrit)

                      unread,
                      Dec 17, 2025, 8:18:03 PM (3 days ago) Dec 17
                      to Etienne Pierre-Doray, Avi Drissman, Chromium Metrics Reviews, Robert Kaplow, Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Dave Tapuska, Etienne Pierre-Doray and Robert Kaplow

                      Avi Drissman voted Code-Review+1

                      Code-Review+1
                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Dave Tapuska
                      • Etienne Pierre-Doray
                      • Robert Kaplow
                      Submit Requirements:
                      • requirement satisfiedCode-Coverage
                      • requirement satisfiedCode-Owners
                      Gerrit-Attention: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Thu, 18 Dec 2025 01:17:52 +0000
                      Gerrit-HasComments: No
                      Gerrit-Has-Labels: Yes
                      satisfied_requirement
                      open
                      diffy

                      Etienne Pierre-Doray (Gerrit)

                      unread,
                      Dec 18, 2025, 9:16:31 AM (2 days ago) Dec 18
                      to Avi Drissman, Chromium Metrics Reviews, Robert Kaplow, Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, Chromium LUCI CQ, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org
                      Attention needed from Dave Tapuska and Robert Kaplow

                      Etienne Pierre-Doray voted Commit-Queue+2

                      Commit-Queue+2
                      Open in Gerrit

                      Related details

                      Attention is currently required from:
                      • Dave Tapuska
                      • Robert Kaplow
                      Gerrit-Attention: Dave Tapuska <dtap...@chromium.org>
                      Gerrit-Comment-Date: Thu, 18 Dec 2025 14:16:13 +0000
                      Gerrit-HasComments: No
                      Gerrit-Has-Labels: Yes
                      satisfied_requirement
                      open
                      diffy

                      Chromium LUCI CQ (Gerrit)

                      unread,
                      Dec 18, 2025, 10:24:20 AM (2 days ago) Dec 18
                      to Etienne Pierre-Doray, Avi Drissman, Chromium Metrics Reviews, Robert Kaplow, Kentaro Hara, Dmitry Gozman, Francois Pierre Doray, Dave Tapuska, Mikhail Khokhlov, AyeAye, chromium...@chromium.org, asvitki...@chromium.org, chromiumme...@microsoft.com, blink-rev...@chromium.org, web-schedulin...@chromium.org, scheduler-...@chromium.org, bnc+...@chromium.org, net-r...@chromium.org, chikamu...@chromium.org, blink-revi...@chromium.org, blink-...@chromium.org, devtools-re...@chromium.org, dtapuska+...@chromium.org, kinuko...@chromium.org, spang...@chromium.org, tracing...@chromium.org, wfh+...@chromium.org

                      Chromium LUCI CQ submitted the change

                      Change information

                      Commit message:
                      [tracing] Migrate TraceLog observers to TraceSessionObserverList

                      This CL implements TraceSessionObserverList and migrate
                      AsyncEnabledStateObserver/EnabledStateObserver to it.
                      The main difference is that TraceSessionObserver is a per-session
                      observer.

                      This is using ObserverListThreadSafe which makes the implementation trivial.

                      Reason:
                      - TraceLog observer doesn't support multiple sessions (legacy reason).
                      This can cause missing updates for several observers that would need it.
                      - Unlike TrackEvent::AddSessionObserver, TraceSessionObserverList sends
                      notification on the task runner where it was requested.
                      - This merges AsyncEnabledStateObserver/EnabledStateObserver;
                      essentially there's no good use case for non async version; otherwise
                      TrackEventSessionObserver can be used directly.
                      - Instead of OnTraceLogEnabled(), this is replaced by
                      TRACE_EVENT_CATEGORY_ENABLED with the relevant category.
                      - One step towards making TraceLog test only.
                      Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Reviewed-by: mmenke <mme...@chromium.org>
                      Reviewed-by: Mikhail Khokhlov <khok...@google.com>
                      Commit-Queue: Etienne Pierre-Doray <etie...@chromium.org>
                      Reviewed-by: Francois Pierre Doray <fdo...@chromium.org>
                      Reviewed-by: Kentaro Hara <har...@chromium.org>
                      Reviewed-by: Avi Drissman <a...@chromium.org>
                      Cr-Commit-Position: refs/heads/main@{#1560543}
                      Files:
                      • M base/BUILD.gn
                      • M base/test/trace_test_utils.cc
                      • M base/trace_event/trace_event_unittest.cc
                      • M base/trace_event/trace_log.cc
                      • M base/trace_event/trace_log.h
                      • A base/trace_event/trace_session_observer.cc
                      • A base/trace_event/trace_session_observer.h
                      • M chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc
                      • M chrome/browser/metrics/pressure/pressure_metrics_reporter.cc
                      • M chrome/browser/metrics/pressure/pressure_metrics_reporter.h
                      • M components/power_metrics/system_power_monitor.cc
                      • M components/power_metrics/system_power_monitor.h
                      • M components/power_metrics/system_power_monitor_unittest.cc
                      • M content/app/content_main.cc
                      • M content/renderer/render_thread_impl.cc
                      • M content/renderer/render_thread_impl.h
                      • M net/log/trace_net_log_observer.cc
                      • M net/log/trace_net_log_observer.h
                      • M services/tracing/public/cpp/trace_startup.cc
                      • M third_party/blink/renderer/core/inspector/worker_inspector_controller.cc
                      • M third_party/blink/renderer/core/inspector/worker_inspector_controller.h
                      • M third_party/blink/renderer/core/paint/timing/paint_timing_visualizer.cc
                      • M third_party/blink/renderer/core/paint/timing/paint_timing_visualizer.h
                      • M third_party/blink/renderer/core/scheduler/task_attribution_tracker_impl.cc
                      • M third_party/blink/renderer/core/scheduler/task_attribution_tracker_impl.h
                      • M third_party/blink/renderer/platform/instrumentation/tracing/trace_event.cc
                      • M third_party/blink/renderer/platform/instrumentation/tracing/trace_event.h
                      • M third_party/blink/renderer/platform/scheduler/main_thread/main_thread_scheduler_impl.cc
                      • M third_party/blink/renderer/platform/scheduler/main_thread/main_thread_scheduler_impl.h
                      • M third_party/blink/tools/blinkpy/presubmit/audit_non_blink_usage.py
                      Change size: L
                      Delta: 30 files changed, 355 insertions(+), 490 deletions(-)
                      Branch: refs/heads/main
                      Submit Requirements:
                      • requirement satisfiedCode-Review: +1 by Kentaro Hara, +1 by Francois Pierre Doray, +1 by Mikhail Khokhlov, +1 by Avi Drissman, +1 by mmenke
                      Open in Gerrit
                      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
                      Gerrit-MessageType: merged
                      Gerrit-Project: chromium/src
                      Gerrit-Branch: main
                      Gerrit-Change-Id: I457ba8b4bb5dab719318d5f70a3b65fc3b642fc7
                      Gerrit-Change-Number: 7234082
                      Gerrit-PatchSet: 29
                      Gerrit-Owner: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Avi Drissman <a...@chromium.org>
                      Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
                      Gerrit-Reviewer: Etienne Pierre-Doray <etie...@chromium.org>
                      Gerrit-Reviewer: Francois Pierre Doray <fdo...@chromium.org>
                      Gerrit-Reviewer: Kentaro Hara <har...@chromium.org>
                      Gerrit-Reviewer: Mikhail Khokhlov <khok...@google.com>
                      Gerrit-Reviewer: Robert Kaplow <rka...@chromium.org>
                      Gerrit-Reviewer: mmenke <mme...@chromium.org>
                      open
                      diffy
                      satisfied_requirement
                      Reply all
                      Reply to author
                      Forward
                      0 new messages