Open Bug 1929210 Opened 3 months ago Updated 3 months ago

Migrating telemetry to Glean increases the XUL size

Categories

(Toolkit :: Telemetry, defect)

defect

Tracking

()

Tracking Status
firefox-esr128 --- unaffected
firefox132 --- wontfix
firefox133 --- wontfix
firefox134 --- fix-optional

People

(Reporter: mayankleoboy1, Unassigned, NeedInfo)

References

(Depends on 1 open bug, Regression)

Details

(Keywords: regression)

Whenever Telemetry probes are migrated to Glean, there is a 0.1% to 0.2% increase in XUL size. Some examples :
here
here
here
here
here
here
here

The increase in XUL size may be expected as some code is moving from js or addon or code outside of XUL to inside XUL. But noting here for posterity.
Additionally, the increase per landing is small (0.1% to 0.2%). However, it may be worthwhile to analyze the overall impact of all the migration/conversion on the size.

Marking initial "regressed by" on bug 1918702, but please change as appropriate.

Adding some folks who may have some opinion.

I think a small size increase is expected, but I don't know how to verify if the increase noticed in the charts linked above is within what's expected or includes excessive overhead.

(Adding Chutten who might have ideas about how much of a size increase is expected, and Markus who might have ideas about how to visualize what actually increased.)

Set release status flags based on info from the regressing bug 1918702

"0.1% to 0.2%" aren't small increases if it happening often
Does bloaty help with the analysis ?

Latest as of 5Nov2024: https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,1884993536&series=autoland,1688129,1,2&timerange=7776000&zoom=1730817020044,1730820454215,144523849.7943846,144612504.87351346

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,101547359&series=autoland,1688129,1,2&timerange=7776000&zoom=1726847828152,1726865266475,141159281.8278438,142260361.2691433

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,104030901&series=autoland,1688129,1,2&timerange=7776000&zoom=1727173088790,1727383009273,140737582.49624163,142821388.60710186

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,104646478&series=autoland,1688129,1,2&timerange=7776000&zoom=1727173088790,1727383009273,140737582.49624163,142821388.60710186

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,105711510&series=autoland,1688129,1,2&timerange=7776000&zoom=1727382266411,1727458701915,141459995.556832,142769652.901816

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,106976175&series=autoland,1688129,1,2&timerange=7776000&zoom=1727711112639,1727715530635,141985789.77957308,142749969.01093823

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,108831823&series=autoland,1688129,1,2&timerange=7776000&zoom=1727953039819,1727957973055,142245678.9237504,142717671.97841713

https://treeherder.mozilla.org/perfherder/graphs?highlightAlerts=1&highlightChangelogData=1&highlightCommonAlerts=0&replicates=0&selected=1688129,108905799&series=autoland,1688129,1,2&timerange=7776000&zoom=1727956555112,1727963882497,142367733.05374968,142784421.87170798

(some of these may be duplicates of what i posted in comment 0)

The generated file toolkit/components/glean/GleanJSMetricsLookup.cpp is holding a lot of static data, and it's size seems to be linear in the number of metric

(In reply to [:sergesanspaille] from comment #5)

The generated file toolkit/components/glean/GleanJSMetricsLookup.cpp is holding a lot of static data, and it's size seems to be linear in the number of metric

This'll be almost entirely due to gMetricStringTable which is broadly analogous to e.g. TelemetryScalarData'h's gScalarsStringTable -- it's all the metric names as strings so JS APIs can reference them (and also so e.g. the profiler can get names for metrics instances for marking). Alas we've found no cheaper way to record these.

Component: General → Telemetry
Product: Firefox Build System → Toolkit
See Also: → 1932617

The severity field is not set for this bug.
:chutten, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(chutten)

Oh, right, I meant to ask: Having large functions seems bad, but in a vague and non-threatening sort of way. Is this a "Fix this now, this is costing us megabux" sort of thing or a "Fix this when you get a chance, this is mildly irritating" sort of thing?

Flags: needinfo?(chutten) → needinfo?(mayankleoboy1)

I cant really comment on that :) . Maybe a build peer or a folks from product may have an opinion here...
ni? you back.

Flags: needinfo?(mayankleoboy1) → needinfo?(chutten)

Sounds like a :glandium-shaped question, then

Flags: needinfo?(chutten) → needinfo?(mh+mozilla)

We have some data which shows that bigger downloads = less installs of Firefox. So, I would like to decrease file sizes when possible with a small/medium investments.
Romain can confirm this.

Flags: needinfo?(mh+mozilla) → needinfo?(rtestard)
You need to log in before you can comment on or make changes to this bug.