Closed Bug 1632467 Opened 5 years ago Closed 5 years ago

Creating AccGroupInfo doesn't clear eGroupInfoDirty

Categories

(Core :: Disability Access APIs, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla77
Tracking Status
firefox77 --- fixed

People

(Reporter: Jamie, Assigned: Jamie)

References

(Blocks 1 open bug)

Details

(Keywords: perf)

Attachments

(1 file)

While prototyping a fix for bug 1627073, I discovered that AccGroupInfo::Update is being called a lot more than it should. It turns out that while we do clear the eGroupInfoDirty flag when we already had GroupInfo and then update it, we do not clear eGroupInfoDirty when we first create GroupInfo. Since we just set eGroupInfoDirty without checking whether there is GroupInfo, that means the flag might still be set after GroupInfo is created. Effectively, that means the cache very frequently doesn't get used.

The initial NVDA buffer render for a simple 7000 item <ul> currently takes ~16.4 seconds. If I clear the flag on GroupInfo creation, that drops to ~4.2 seconds. That's a 3.9x perf boost.

When the tree is mutated, we set eGroupInfoDirty regardless of whether there is GroupInfo.
Previously, we cleared eGroupInfoDirty when updating GroupInfo, but not when creating it.
This meant that the flag was often still set, causing the cache to not be used a lot of the time.

Pushed by mzehe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/6998e2f1e2d8 Clear eGroupInfoDirty flag when creating AccGroupInfo. r=MarcoZ
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla77
Regressions: 1635309
Blocks: 1473310
Blocks: a11yperf
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: