Closed Bug 1823644 Opened 1 year ago Closed 1 year ago

Optimize textrun initialization by merging SanitizeGlyphRuns and SortGlyphRuns

Categories

(Core :: Graphics: Text, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
113 Branch
Tracking Status
firefox113 --- fixed

People

(Reporter: jfkthame, Assigned: jfkthame)

References

Details

Attachments

(1 file)

After the initial creation of glyph runs in a gfxTextRun instance, we make two "cleanup" passes over the array of runs: first, SanitizeGlyphRuns adjusts for ligature boundaries if necessary, and eliminates any runs that end up empty as a result; and then SortGlyphRuns ensures they are ordered by character offset, and merges any adjacent runs with identical properties.

With a bit of care, I think we can merge these and do the cleanup in a single pass.

No change in behavior, just a marginal optimization when creating large/complex textruns.

Assignee: nobody → jfkthame
Status: NEW → ASSIGNED
Pushed by jkew@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/e77d576d2a1b
Optimize textrun initialization by merging SanitizeGlyphRuns and SortGlyphRuns. r=gfx-reviewers,lsalzman
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 113 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: