Closed Bug 851847 Opened 8 years ago Closed 8 years ago

Optimize nsBlockFrame::StealFrame when removing a normal flow child

Categories

(Core :: Layout: Block and Inline, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla22

People

(Reporter: mats, Assigned: mats)

References

(Blocks 1 open bug)

Details

(Keywords: perf)

Attachments

(1 file)

nsBlockFrame::StealFrame currently does a linear search over all lines
(including overflow lines) to find the given child frame.

We can optimize this in two ways: first, we now have a hash table for
lines that have many (>200) frames - we should use it when available;
second, we should test upfront if the given child is an inline or block
and then skip lines accordingly.
Blocks: 834096
Comment on attachment 725823 [details] [diff] [review]
fix

r=me
Attachment #725823 - Flags: review?(bzbarsky) → review+
Oops, the above changeset had some unrelated changes in it -- backed out.
https://hg.mozilla.org/mozilla-central/rev/a5170d1c3bac
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla22
You need to log in before you can comment on or make changes to this bug.