Skip to content

Comment the memory of every implementation on pull requests - #21

Merged
linghengqian merged 2 commits into
mainfrom
jammy-dolphin
Oct 23, 2026
Merged

linghengqian merged 2 commits into
mainfrom
jammy-dolphin

Conversation

@linghengqian

@linghengqian linghengqian commented Oct 23, 2026 •

Copy link
Copy Markdown
Member

The workflow of each implementation uploads the numbers of its measure scenario as the artifact memory-. shared/tools/measure.sh writes them to the file in VFOX_PLUS_MEASURE_OUTPUT as well as to the log; Flutter's tool/measure.py already wrote memory.txt.

memory.yml starts after each of those workflows ends, in the context of main, so that it also works for pull requests of forks, and .github/scripts/memory_report.py stops while another one is still running for the commit. The run after the last one writes one comment on the pull request: the table of docs/memory.md, sorted by the PSS of the Home page, with the difference from the latest run of the same workflow on main. An implementation that the pull request did not rebuild shows the numbers of main. Later commits replace the comment instead of adding another one.

The same code does not use the same memory in every CI run. In the 107 runs of 2026-10-18 and 19 that shared their source with another one (30 groups of 2 to 8 runs), the PSS differed by up to 4.3 % for mygo, Uno, Capacitor, Tauri, Dioxus and Wails, by up to 7.5 % for Compose and Flet, and by 11 to 13 % for Gio and Flutter. A difference is a change, in bold, only when it is more than 5 MB and 5 % of the number on main (8 % for Compose and Flet, 12 % for Gio, 15 % for Flutter); none of the 940 comparisons of identical code was one by these limits. A different number of processes is a change too: it never varied.

The script reads nothing but two lines of numbers from the artifacts of the pull request, which are not trusted. Its tests (83, run by the Repository workflow) use a fake of the API, and were also checked against the real one with read-only requests.

The workflow of each implementation uploads the numbers of its measure
scenario as the artifact memory-<implementation>. shared/tools/measure.sh
writes them to the file in VFOX_PLUS_MEASURE_OUTPUT as well as to the
log; Flutter's tool/measure.py already wrote memory.txt.

memory.yml starts after each of those workflows ends, in the context of
main, so that it also works for pull requests of forks, and
.github/scripts/memory_report.py stops while another one is still running
for the commit. The run after the last one writes one comment on the pull
request: the table of docs/memory.md, sorted by the PSS of the Home page,
with the difference from the latest run of the same workflow on main. An
implementation that the pull request did not rebuild shows the numbers of
main. Later commits replace the comment instead of adding another one.

The same code does not use the same memory in every CI run. In the 107
runs of 2026-10-18 and 19 that shared their source with another one (30
groups of 2 to 8 runs), the PSS differed by up to 4.3 % for mygo, Uno,
Capacitor, Tauri, Dioxus and Wails, by up to 7.5 % for Compose and Flet,
and by 11 to 13 % for Gio and Flutter. A difference is a change, in bold,
only when it is more than 5 MB and 5 % of the number on main (8 % for
Compose and Flet, 12 % for Gio, 15 % for Flutter); none of the 940
comparisons of identical code was one by these limits. A different number
of processes is a change too: it never varied.

The script reads nothing but two lines of numbers from the artifacts of
the pull request, which are not trusted. Its tests (83, run by the
Repository workflow) use a fake of the API, and were also checked
against the real one with read-only requests.
@linghengqian linghengqian added the enhancement New feature or request label Oct 23, 2026
Comment thread .github/scripts/memory_report.py Fixed
py/clear-text-logging-sensitive-data treats every name that contains
"trusted" as secret data. It flagged the artifact name and ID that
read_artifact() logs when it cannot read an artifact (memory_report.py,
line 418), through the list that baseline_of() called "trusted". Nothing
secret is logged: the list only held the artifacts that were made on the
default branch.
@linghengqian
linghengqian marked this pull request as ready for review October 23, 2026 07:06
@linghengqian
linghengqian merged commit 79ef675 into main Oct 23, 2026
34 checks passed
@linghengqian
linghengqian deleted the jammy-dolphin branch October 23, 2026 07:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants