Skip to content

[record_use] Implementation: JSON: Use loading unit should be a list #3022

Closed

Description

@dcharkes

The compiler might duplicate code by inlining, this should then either (1) result in a call with two loading units, or (2) two identical calls with one loading unit.

A developer might write code that uses exactly the same const instance from two loading units. This should either lead to (1) two const instances being recorded with both a single loading unit or (2) a single const instance being recorded with multiple loading units.

(Assets output from a link hook should have a list of loading units as well, multiple calls can contribute to 1 asset. As long as we don't give access to the loading unit graph in the link hook, the link hook will need to output all loading units an asset is used in. And then the SDK can decide to put the asset in the dominating loading unit; or in the leaves if asset loading is deduplicated in that SDK.)

cc @biggs0125

  • record-use format
  • dart compiler emitting multiple loading units
  • integration tests for multiple loading units in Dart SDK

Activity

  1. moved this from Todo to In Progress in Native Assetson Feb 19, 2026
  2. self-assigned this
    on Feb 19, 2026
  3. dcharkes commented on Feb 27, 2026

    @dcharkes
    CollaboratorAuthor

    The JSONs are now a list in the format.

  4. moved this from In Progress to Done in Native Assetson Feb 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions