Closed Bug 1360881 Opened 7 years ago Closed 6 years ago

stylo: We allocate too much during the cascade

Categories

(Core :: CSS Parsing and Computation, enhancement, P4)

enhancement

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox57 --- wontfix

People

(Reporter: bholley, Assigned: bholley)

References

(Depends on 1 open bug)

Details

In the profile in bug 1360878 comment 1, we spend 11ms in malloc/free, which is too much. There are a couple of sources for this, and I'll file dependent bugs.

Note that this is about sequential performance. In bug 1291355 Julian is investigating contention issues that (we think) makes malloc blow up when parallelized. So any malloc reduction here will dovetail with whatever we find out there.
Depends on: 1360882
Depends on: 1347852
Depends on: 1360776
We should also refcount inherited-by-default types.
I think before considering implementing our own Arc, we should fix the dumb stuff we do. I've opened https://github.com/servo/servo/pull/16664 to do that, which should make the comparison actually useful.
Depends on: 1361392
Bobby, how does bug 1361392 block this? That's text shaping code, so shouldn't affect styling, only layout.
Flags: needinfo?(bobbyholley)
Oh, I just saw that it was allocation-related and blocked bug 1360878. So I guess the real question is why it blocks bug 1360878...
Flags: needinfo?(bobbyholley) → needinfo?(jseward)
No longer depends on: 1361392
I was unclear whether this was part of styling or not; evidently not.
So the blocking of bug 1360878 is wrong, IIUC.
Flags: needinfo?(jseward)
Yeah, I suggested Julian to report the memory inefficiencies he found while investigating that test case blocking bug 1360878, and triage them later. My fault, should've removed that dependency. But the report was quite useful anyway :)
Priority: -- → P1
Depends on: 1356701, 1360772
Priority: P1 → P4
status-firefox57=wontfix unless someone thinks this bug should block 57
We fixed a lot of stuff in this area, and things look pretty good here at this point.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.