Add PerfStats in more places in a11y code
Categories
(Core :: Disability Access APIs, task)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox137 | --- | fixed |
People
(Reporter: Jamie, Assigned: morgan)
References
(Blocks 1 open bug)
Details
(Whiteboard: [a11yPerf24h2])
Attachments
(6 external files)
After discussion with the performance team, we've determined that PerfStats are likely to be the most helpful measurements in determining performance improvements/regressions in accessibility code. To that end, we want to add PerfStats in a bunch of additional places which are potential hot paths. To make diagnosis easier, all PerfStats should also have corresponding profile markers.
- a11y::PlatformShowHideEvent: Firing show and hide events to the OS.
- DocAccessible::ContentRemoved
- DocAccessible::PruneOrInsertSubtree: Deciding whether to add or remove an Accessible when layout changes.
- DocAccessible::ShutdownChildrenInSubtree
- DocAccessibleChild::ShowEvent: Sending newly inserted Accessibles, including cache data.
- DocAccessibleParent::RecvCache: Receiving cache updates.
- DocAccessibleParent::RecvHideEvent: Processing removals from the RemoteAccessible tree.
- DocAccessibleParent::RecvShowEvent: Processing insertions into the RemoteAccessible tree, including updating the cache.
- EventQueue::CoalesceEvents
- LocalAccessible::SendCache (already has a profiler marker)
- NotificationController::CoalesceMutationEvents
- NotificationController::WillRefresh (already has a profiler marker)
- NotifyWinEvent: Firing events to Windows specifically.
- nsAccessibilityService::Init (already has a profiler marker)
| Reporter | ||
Updated•2 years ago
|
| Reporter | ||
Updated•2 years ago
|
| Reporter | ||
Comment 1•2 years ago
|
||
Hi :bdekoz. I'm looking into adding these new PerfStats, but I just spotted that PerfStats has a MetricMask type which is a uint64_t. If I understand this correctly, that means we can only have 63 metrics in total with the current implementation. There are already 31 of them and this bug proposes adding 14 more. That's obviously still below the limit, but it does mean a11y would be disproportionately consuming slots in a limited pool. Should we be trying to narrow this list down further or is that a problem you/someone else is happy to deal with later?
Comment 2•2 years ago
|
||
Hey, sorry about the delay here. It's great to see the scope of your ambition here. Is there any way you can prioritize this into a group 1, group 2? Or are all of these the same priority in terms of data needs? I don't think that 14 new flags is necessarily a deal breaker, but it would be great to be able to stage this in multiple bites.
I'm currently working on getting metadata about a11y use into another ping, the performance page load event. Can this wait until that is done?
Updated•2 years ago
|
| Reporter | ||
Comment 3•2 years ago
|
||
(In reply to Benjamin De Kosnik [:bdekoz] from comment #2)
Is there any way you can prioritize this into a group 1, group 2?
Here's an initial attempt to split these into priority buckets:
- High priority:
- DocAccessible::ContentRemoved
- DocAccessible::PruneOrInsertSubtree: Deciding whether to add or remove an Accessible when layout changes.
- DocAccessible::ShutdownChildrenInSubtree
- DocAccessibleChild::ShowEvent: Sending newly inserted Accessibles, including cache data.
- DocAccessibleParent::RecvCache: Receiving cache updates.
- DocAccessibleParent::RecvShowEvent: Processing insertions into the RemoteAccessible tree, including updating the cache.
- EventQueue::CoalesceEvents
- NotificationController::CoalesceMutationEvents
- Medium priority:
- DocAccessibleParent::RecvHideEvent: Processing removals from the RemoteAccessible tree.
- LocalAccessible::SendCache (already has a profiler marker)
- NotificationController::WillRefresh (already has a profiler marker)
- Most of the problems we might see here should be caught by other metrics we already have or high priority new metrics listed above; i.e. those other hot paths are all wrapped inside WillRefresh.
- Low priority:
- a11y::PlatformShowHideEvent: Firing show and hide events to the OS.
- NotifyWinEvent: Firing events to Windows specifically.
- nsAccessibilityService::Init (already has a profiler marker)
Morgan, on a brief look, what do you think about the buckets here? Do you think we can move more out of high priority? I was thinking of moving DocAccessible::ShutdownChildrenInSubtree out, but we have at least one bug where we think this is causing problems and we have no other way of measuring it right now, so I'm a bit reluctant to move it out.
I'm currently working on getting metadata about a11y use into another ping, the performance page load event. Can this wait until that is done?
Yes. There's no urgency here; we'd just like to keep the momentum going so we do have a good a11y perf metrics story in the not too distant future.
| Assignee | ||
Comment 4•1 year ago
|
||
(In reply to James Teh [:Jamie] from comment #3)
(In reply to Benjamin De Kosnik [:bdekoz] from comment #2)
Is there any way you can prioritize this into a group 1, group 2?
Here's an initial attempt to split these into priority buckets:
...
Morgan, on a brief look, what do you think about the buckets here? Do you think we can move more out of high priority? I was thinking of moving DocAccessible::ShutdownChildrenInSubtree out, but we have at least one bug where we think this is causing problems and we have no other way of measuring it right now, so I'm a bit reluctant to move it out.
I think these look good -- we ended up discussing this briefly on a zoom call :)
:bdekoz -- can you say more about what the page load ping would get us / what work is involved there?
| Assignee | ||
Updated•1 year ago
|
Comment 5•1 year ago
•
|
||
sorry, this was discussed in person and I'm now circling back. I think this plan is the right form, we can do this in the manner specified. I'm no longer insisting on or even suggesting smaller bites or staging this, although it was useful to see what you are thinking in terms of prioritization. For visualizing results, and getting results from CI, perfstats will work great and so we should concentrate on that for now. Once we have more experience we can think about expanding out and getting telemetry/RUM in the exact same fashion when we know lab results look good.
page load ping is more about trying to get metadata that is useful for a11y into telemetry results, into bigquery tables, like what AT are active in a given pageloads, or in a given set of 30 page loads. That would be for giving a11y a handle on analyzing telemetry, where partitions could be selected such as
this population has a AT device enabled
or
this population has no AT enabled
or
this population has a screen reader enabled.
Those kinds of segments. That's a separable task, so let's concentrate on the metrics in this bug, getting measurements from CI, getting reproducible performance results with these metrics. The data analysis/telemetry parts can go here: https://bugzilla.mozilla.org/show_bug.cgi?id=1932691
| Assignee | ||
Comment 6•1 year ago
|
||
| Assignee | ||
Comment 7•1 year ago
|
||
Updated•1 year ago
|
Updated•1 year ago
|
| Assignee | ||
Comment 8•1 year ago
|
||
Depends on D237276
| Assignee | ||
Comment 9•1 year ago
|
||
Depends on D237647
| Assignee | ||
Comment 10•1 year ago
|
||
Depends on D237648
| Assignee | ||
Comment 11•1 year ago
|
||
Depends on D237649
| Assignee | ||
Comment 12•1 year ago
|
||
:Jamie do you think its worth adding a marker for RecvMutationEvents? I migrated the two RecvShow/HideEvent markers to the newly named ProcessShow/HideEvent functions, but I'm wondering if we should add a marker for this new function too.
Comment 13•1 year ago
|
||
Comment 14•1 year ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/d0959ee85725
https://hg.mozilla.org/mozilla-central/rev/adaca3ddb615
https://hg.mozilla.org/mozilla-central/rev/c7209fc76943
https://hg.mozilla.org/mozilla-central/rev/478c0496cae7
https://hg.mozilla.org/mozilla-central/rev/6588d87b15a0
https://hg.mozilla.org/mozilla-central/rev/8242e03983b7
| Assignee | ||
Updated•1 year ago
|
Description
•