Closed Bug 1711577 Opened 3 years ago Closed 3 years ago

APZ logging improvement: print whether an APZC is the root or a subframe

Categories

(Core :: Panning and Zooming, task, P3)

task

Tracking

()

RESOLVED FIXED
101 Branch
Tracking Status
firefox101 --- fixed

People

(Reporter: botond, Assigned: dlrobertson)

References

Details

Attachments

(1 file)

One of the things that makes APZ logs cumbersome to interpret is that often there is more than one APZC in the layer tree, and logs from different APZCs are interspersed.

Often, we are only interested in logs from one APZC (often the root, other times a particular subframe on the page). You can figure out which APZC that is from the logs (usually by looking at a line that prints the frame metrics), but for other log messages you have to associate them by the APZC address.

We could improve a bit by printing (root) or (subframe) next to the APZC address (or for subframes, perhaps also the scroll ID, to distinguish different subframes from each other), which would make it easier to filter for just the APZC of interest.

I'm mainly imagining doing this for the state change messages (which we are further improving in bug 1711574), but we could consider doing it for all of them.

We also log a content description here

https://searchfox.org/mozilla-central/rev/cecdac0aa5733fee515a166b6e31e38cc58abf32/layout/base/nsLayoutUtils.cpp#8822

Outputting that along with the scroll guid at that point would be helpful to find the azpc you care about if it isn't root (and make sure the guid is output everywhere so it's more easily searchable perhaps). The content description could even be put on the metrics in certain situations (debug builds?) and output on the compositor side logs.

(In reply to Timothy Nikkel (:tnikkel) from comment #1)

We also log a content description here

https://searchfox.org/mozilla-central/rev/cecdac0aa5733fee515a166b6e31e38cc58abf32/layout/base/nsLayoutUtils.cpp#8822

Outputting that along with the scroll guid at that point would be helpful to find the azpc you care about if it isn't root (and make sure the guid is output everywhere so it's more easily searchable perhaps).

Yep, good idea.

The content description could even be put on the metrics in certain situations (debug builds?) and output on the compositor side logs.

It's put on the ScrollMetadata a few lines below the place you linked (if one of the prefs in question is set), and we do print it in the apz.printtree logs (but like you say it would be useful to print it in more places).

Assignee: nobody → drobertson
Pushed by tnikkel@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/338972c49ae8 Add is-root and scroll id to APZC logs to better distinguish the root and subframes. r=tnikkel
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 101 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: