Try to avoid building hit test info items for positioned descendants
Categories
(Core :: Web Painting, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox67 | --- | fixed |
People
(Reporter: mattwoodrow, Assigned: mattwoodrow)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
Currently we force a new HitTestInfo item each time we encountered a positioned frame [1].
This is because we sort the PositionedDescendants list, and even if the current frame's hit-test info matches the existing item, a future item might be different, and then be sorted into the middle.
For pages like maze solver [2], there are a massive number of positioned items, so we end up with a lot of hit-test items (even for otherwise hidden content, like the circle marker in each cell).
We shouldn't actually need these items in a lot of cases, since all hit-test items should be the same, and the sorting doesn't affect anything.
It seems like we should be able to check in advance to see if any descendants have styles that would make it possible for alternative hit-test flags to be created (cached as a frame state bit?), and we can skip this if we know all items will be identical.
We could also probably do culling of items during the Gecko->WR DL conversion pass, though we've already paid a large chunk of the cost, so I think that's a secondary priority.
[1] https://searchfox.org/mozilla-central/rev/4587d146681b16ff9878a6fdcba53b04f76abe1d/layout/generic/nsFrame.cpp#3772
[2] https://testdrive-archive.azurewebsites.net/Performance/MazeSolver/Default.html
Assignee | ||
Comment 1•6 years ago
|
||
Assignee | ||
Updated•6 years ago
|
Comment 3•6 years ago
|
||
bugherder |
Description
•