Arabic-character processing in nsTextFrameUtils::TransformText is out of date

RESOLVED FIXED in mozilla16

Status

()

Core
Layout: Text
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: jfkthame, Assigned: jfkthame)

Tracking

({intl})

unspecified
mozilla16
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
Created attachment 632276 [details] [diff] [review]
update and optimize Arabic char processing in TransformText

nsTextFrameUtils::TransformText is responsible for detecting Arabic characters, in order to support the bidi.numeral processing within textruns. However, the macros it uses to identify Arabic characters are out of date with respect to Unicode (they don't account for the Arabic Supplement and Extension blocks). They can also be rewritten slightly to run more efficiently, which is important because TransformText is showing up as a significant contributor to profiles in bug 762710, for example.

The attached patch updates the Arabic character range, and by optimizing the order of comparisons, it also shaves around 5-10ms off the reflow time for the tinderbox log in bug 762710#c0 (on my MBP).
Attachment #632276 - Flags: review?(smontagu)
Attachment #632276 - Flags: review?(smontagu) → review+
(Assignee)

Comment 1

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/42e5e3988682
Assignee: nobody → jfkthame
Target Milestone: --- → mozilla16

Comment 2

5 years ago
https://hg.mozilla.org/mozilla-central/rev/42e5e3988682
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.