Closed Bug 1377262 Opened 7 years ago Closed 7 years ago

substitute_variables_slow functions generate huge amounts of code

Categories

(Core :: CSS Parsing and Computation, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla56

People

(Reporter: away, Assigned: SimonSapin)

References

(Blocks 1 open bug)

Details

https://pastebin.mozilla.org/9026066 In a recent stylo build there's a total of 908k in closures, almost all of which are of the form "style::properties::substitute_variables_XYZ_slow<closure>". Simon, is there anything that can be done to reduce this?
Flags: needinfo?(simon.sapin)
Oh, I misunderstood the function names. These functions aren't the closures themselves, they're actually functions substitute_variables_XYZ_slow<F>, which are instantiated with a closure for F.
Summary: substitute_variables closures generate huge amounts of code → substitute_variables_slow functions generate huge amounts of code
Assignee: nobody → simon.sapin
Flags: needinfo?(simon.sapin)
https://github.com/servo/servo/pull/17703 fixes this and more. It saves 1.6 to 2 megabytes, depending on what is measured.
Amazing! I don't plan to measure all changes on Windows, but for this one I couldn't resist. 79479808 xul.dll 81366528 xul.dll.before Assuming the PR lands as is, that's more than 1.8M saved on Win64. Go Simon!
https://github.com/servo/servo/pull/17703 has landed in the servo repo but I can’t find it in https://hg.mozilla.org/integration/autoland . Is vcs-sync down?
(In reply to Simon Sapin (:SimonSapin) from comment #4) > https://github.com/servo/servo/pull/17703 has landed in the servo repo but I > can’t find it in https://hg.mozilla.org/integration/autoland . Is vcs-sync > down? autoland is currently closed due to the OSX symbols issue: https://treeherder.mozilla.org/#/jobs?repo=autoland
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in before you can comment on or make changes to this bug.