Skip to content

Counter samples continue until the end of track #3341

@znoffel

Description

@znoffel

When using counter events ("ph":"C") in Chrome Trace Event JSON Format, the last counter value automatically extends horizontally until the end of the entire trace timeline, even when the measurement has actually stopped. This happens when opening a JSON trace file in Perfetto UI, but not the legacy Chrome viewer. For example:

Image

Our desired behavior is to indicate that measurement has ended, rather than extending the last value indefinitely. Ideally:

  • The counter line stops at the last sample timestamp
  • Or shows a visual indication that no more data is available
  • Or drops to null/undefined to indicate "no data"

Is there a recommended way to terminate a counter track to prevent this extension? We considered the idea of adding a final counter event with value 0 (but this is inaccurate + the line still continues)
@LalitMaganti

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions