Closed Bug 1472546 Opened 2 years ago Closed 1 year ago
Moving position:absolute elements performance far worse (i
.e . terrible) with vertical-rl pages than vertical-lr pages
User Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:62.0) Gecko/20100101 Firefox/62.0 Build ID: 20180625141512 Steps to reproduce: Attached html file reproduces this problem. This problem also affects Japanese popup dictionary addons (like rikaichamp, and mine, nazeka) when used on pages of vertical Japanese text, rendering them nearly unusable because the popup dictionary performs so badly. Interestingly, performance is fine if the body element has vertical-rl instead of the html element, but this causes the page to start at the "bottom" (left side) instead of the "top" (right side). The problem is not the location on the page that the element is positioned. More elaborate pages make the performance problem worse. The profiler shows that reflowing is taking up a lot of time. It takes up far less, only a couple milliseconds, on vertical-lr pages. It takes up even more time on organic vertical-rl pages with lots of images. https://i.imgur.com/k5gXLLy.png Actual results: Performance of html element writing mode vertical-rl is far worse than html element writing mode vertical-lr or body element writing mode vertical-rl. Expected results: Performance of html element writing mode vertical-rl should be similar to html element writing mode vertical-lr or body element writing mode vertical-rl.
I left this line in the repro file on accident: let unused = document.elementFromPoint(0,0); it has no effect on performance. I added it, because popup dictionaries do similar things, to see if it made a difference (for the worse) and it didn't.
2 years ago
Component: General → Layout
Status: UNCONFIRMED → NEW
Ever confirmed: true
Whiteboard: [qf] → [qf:p3:responsiveness]
Assignee: nobody → emilio
Status: NEW → ASSIGNED
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/autoland/rev/2e851e8aac47 Make the RecomputePosition optimization work on vertical-rl writing-modes. r=jfkthame
You need to log in before you can comment on or make changes to this bug.