Closed
Bug 1371157
Opened 8 years ago
Closed 8 years ago
cache results of system font lookups on Windows
Categories
(Core :: Widget: Win32, defect)
Tracking
()
Tracking | Status | |
---|---|---|
firefox55 | --- | fixed |
People
(Reporter: dbaron, Assigned: dbaron)
References
(Blocks 1 open bug)
Details
(Keywords: perf)
Attachments
(2 files)
2.00 KB,
patch
|
jimm
:
review+
|
Details | Diff | Splinter Review |
5.72 KB,
patch
|
jimm
:
review+
|
Details | Diff | Splinter Review |
Profiling bug 1118086 on Windows shows that about 8% of the time in the big pause in the parent process to render a large select is time spent in mozilla::LookAndFeel::GetFont. See the profile in https://perfht.ml/2qYJjqQ .
(Contrast with Linux, where time was spent in GetWidgetPadding / GetWidgetBorder; see bug 1367576.)
Caching the results of these repeated system font lookups should be a performance win, and should be pretty straightforward.
Assignee | ||
Comment 1•8 years ago
|
||
Assignee | ||
Comment 2•8 years ago
|
||
MozReview-Commit-ID: 8bwmXmBFZB4
Attachment #8875806 -
Flags: review?(jmathies)
Assignee | ||
Comment 3•8 years ago
|
||
I haven't really tested that this fixes the performance problem observed
in a profile without the patch because the steps to use the Gecko
Profiler on local builds on Windows are rather complicated.
MozReview-Commit-ID: FmGFs2Cvquv
Attachment #8875807 -
Flags: review?(jmathies)
Assignee | ||
Comment 4•8 years ago
|
||
(The instructions for the "rather complicated" bit are: https://developer.mozilla.org/en-US/docs/Mozilla/Performance/Profiling_with_the_Built-in_Profiler_and_Local_Symbols_on_Windows , for what it's worth.)
Updated•8 years ago
|
Whiteboard: [qf] → [qf:p1]
![]() |
||
Updated•8 years ago
|
Attachment #8875806 -
Flags: review?(jmathies) → review+
![]() |
||
Updated•8 years ago
|
Attachment #8875807 -
Flags: review?(jmathies) → review+
Assignee | ||
Comment 5•8 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/aa3557e8515c8a8a1cbab8f5a5614476cc68ffe6
Bug 1371157 - Use override keyword in windows nsLookAndFeel header. r=jimm
https://hg.mozilla.org/integration/mozilla-inbound/rev/70c026121670bd42e43bb87334fec1fd848b77d9
Bug 1371157 - Cache results of Windows system font lookups. r=jimm
Comment 6•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/aa3557e8515c
https://hg.mozilla.org/mozilla-central/rev/70c026121670
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
Assignee | ||
Comment 7•8 years ago
|
||
I verified that it fixed what I expected by reprofiling in today's nightly.
In today's nightly, 7ms are spent inside of ComputeFontData: https://perfht.ml/2svcp5g
Whereas in the profile from comment 0, that was 172ms: https://perfht.ml/2suzJAk of which 159ms was spent inside nsRuleNode::ComputeSystemFont (compared to 0 in today's nightly).
Updated•3 years ago
|
Performance Impact: --- → P1
Whiteboard: [qf:p1]
You need to log in
before you can comment on or make changes to this bug.
Description
•