Skip to content

[meta] Share more data between threads #3918

@mstange

Description

@mstange

Our profiles currently contain the following pieces of information which are shared between threads:

And for each thread, we have the following pieces of information per thread:

  • resourceTable
  • stringTable
  • nativeSymbols
  • funcTable
  • frameTable
  • stackTable
  • actual per-thread data, such as thread names, start / end times, samples, and allocations

We should move more of these per-thread tables into the shared part of the profile. This will reduce duplication, leading to smaller profile upload sizes and smaller in-memory sizes. It should also simplify some of the code involved in merging or diffing threads, though most of the merging logic will still exist for profile processing and for profile merging.

Furthermore, having function IDs which are consistent between threads will make it easier to switch between multi-thread views and single-thread views without losing your place. For example, it would make it easier to apply call tree transforms to multiple threads at the same time, without losing them when switching back to the single-thread view.

┆Issue is synchronized with this Jira Task

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