Commit Graph

14832 Commits

Author SHA1 Message Date
Behdad Esfahbod 3ea0f37c30 [subset-cff] Move an init to constructor
The init was not called anyway.
2022-11-28 13:58:44 -07:00
Behdad Esfahbod 6c92c3e0cf [subset-cff] Remove unnecessary check 2022-11-28 13:54:24 -07:00
Behdad Esfahbod 7fd300dd9a [subset-cff] Use constructor for parsed_cs_op_t 2022-11-28 13:51:16 -07:00
Garret Rieger bd37900e0d [subset] use a reference to cached global/loca subrs.
Previously they were being copied in. Copying is no longer necessary now that hint dropping doesn't mutate the arrays.
2022-11-28 13:43:52 -07:00
Behdad Esfahbod ded9de9cd8 [cff] bsearch in fdselect
Saves 8% in NotoSansCJK / 10000 subset benchmark.
2022-11-28 13:32:08 -07:00
Behdad Esfahbod 0c33aba30c [subset-cff] Rename drop flag to hinting flag 2022-11-28 12:28:13 -07:00
Behdad Esfahbod 6f5b531986 [subset-cff] Make no-hinting use accelerator as well 2022-11-28 12:24:29 -07:00
Behdad Esfahbod fad8322b3f [benchmark-subset] Add no-hinting ops 2022-11-27 15:09:48 -07:00
Behdad Esfahbod f51a624e67 [subset-cff] Micro-optimize drop_hints_in_str 2022-11-27 14:54:39 -07:00
Behdad Esfahbod 3860326688 [subset-cff] Write loop more idiomatic 2022-11-27 13:23:13 -07:00
Behdad Esfahbod 3ff502d3ae [subset-cff] Remove unnecessary initialization 2022-11-27 12:58:04 -07:00
Behdad Esfahbod 6af4985bf9 [subset-cff] No need for bitflag here anymore 2022-11-26 18:20:20 -07:00
Behdad Esfahbod 69ce606d14 [subset-cff] Immediately drop subr numbers instead of marking for skip
Seems to work and saves ~2% time.
2022-11-26 18:18:35 -07:00
Behdad Esfahbod 1cf4f3e083 [subset-cff] More comment 2022-11-26 18:15:28 -07:00
Behdad Esfahbod f68221ff43 [subset-cff] Add comment 2022-11-26 18:12:14 -07:00
Behdad Esfahbod 048ab8a066 [subset-cff] Remove unused bits 2022-11-26 18:00:43 -07:00
Behdad Esfahbod 37cbfc0c7e [subset-cff] Remove unneeded member 2022-11-26 17:57:44 -07:00
Behdad Esfahbod 46ab15137b [subset-cff] Add has_calls to parsed charstrings
Optimize closure based on it.
2022-11-26 17:49:21 -07:00
Behdad Esfahbod 6d53074e63 [subset-cff] Drop another unused parameter 2022-11-26 17:23:09 -07:00
Behdad Esfahbod 42615561b5 Optimize a couple array references 2022-11-26 17:13:20 -07:00
Behdad Esfahbod 04d23b7ca8 [subset-cff] Micro-optimize collect_subr_refs_in_str 2022-11-26 17:08:00 -07:00
Behdad Esfahbod 9d18180c3c [array] Use hb_hash instead of handrolling 2022-11-26 15:38:21 -07:00
Behdad Esfahbod 1e6f77c250 [benchmark-subset] Adjust num glyphs more 2022-11-26 15:31:56 -07:00
Behdad Esfahbod 0382defa51 [benchmark-subset] Adjust number of glyphs of fonts 2022-11-26 15:27:07 -07:00
Behdad Esfahbod 4cb441dfd1 [benchmark-subset] Add AdobeVFPrototype 2022-11-26 15:23:07 -07:00
Behdad Esfahbod e302b9d5da Fix build 2022-11-26 15:18:16 -07:00
Behdad Esfahbod 70d97d079b [subset-cff] Remove unused argument 2022-11-26 15:16:11 -07:00
Behdad Esfahbod 4167e93a15 [subset-cff2] Micro-optimize blend operator 2022-11-26 15:14:52 -07:00
Behdad Esfahbod f159bf075b [cff2] Micro-optimize blend operator 2022-11-26 15:11:32 -07:00
Behdad Esfahbod a331e913dc [bit-page] Hand-code equality
Faster than memcmp() because of alignment.
2022-11-26 14:59:37 -07:00
Behdad Esfahbod 9df06a2695 [bit-set] Fix is_subset() short-circut criteria
Ouch!
2022-11-26 14:56:45 -07:00
Behdad Esfahbod 915c1a00cf [vector] Add remove_unordered
Saves 5% in NotoNastaliq/1000 subset benchmark.
2022-11-26 14:48:57 -07:00
Behdad Esfahbod 4b8d8fbee4 [ot-map] Micro-optimize for size 2022-11-26 14:31:15 -07:00
Behdad Esfahbod 93f3a9dbc6 [ot-map] Micro-optimize more
Another 500 bytes.
2022-11-26 14:25:21 -07:00
Behdad Esfahbod f39f049870 [ot-map] Micro-optimize
Weird that shrinks size by 500 bytes.
2022-11-26 14:16:15 -07:00
Behdad Esfahbod 60bb32c454 [ot-map] Minor refactor 2022-11-26 14:12:57 -07:00
Behdad Esfahbod e3cc61838f [PairPos] Adjust kerning buffer messages 2022-11-26 13:58:04 -07:00
Behdad Esfahbod a81dd1053d [layout] Adjust printing feature tags
For required-feature, print spaces, not nul bytes.
2022-11-26 13:43:36 -07:00
Behdad Esfahbod 56e3868b52 [layout/buffer-message] Print feature name in lookup buffer messages 2022-11-26 13:14:23 -07:00
Garret Rieger a5d35fd80a [subset] use charstrings directly from accelerator cache if mutability isn't needed. 2022-11-25 16:50:55 -07:00
Behdad Esfahbod 026b64ef76 [subset-cff] Avoid set mallocation in hb_plan_subset_cff_fdselect 2022-11-25 14:57:40 -07:00
Behdad Esfahbod 74acf52f33 [subset-cff] Micro-optimize copy_str more 2022-11-25 14:43:44 -07:00
Behdad Esfahbod d2f3cde7ef [subset-cff] Micro-optimize copy_str 2022-11-25 14:38:30 -07:00
Behdad Esfahbod e333223f26 [array] Optimize serializing copy() 2022-11-25 14:26:02 -07:00
Behdad Esfahbod 22990fca1d
Merge pull request #3894 from googlefonts/cff_accel
[subset] Cache parsed char strings in CFF accelerator
2022-11-25 14:12:58 -07:00
Garret Rieger 8d5c899b0f [subset] In cff accelerator hold reference to CFF table instead of the whole font. 2022-11-25 20:53:20 +00:00
Behdad Esfahbod 7b197446ac [vector] Adjust for HB_OPTIMIZE_SIZE 2022-11-25 13:28:53 -07:00
Garret Rieger 75a99f28ab [subset] destruct cff accelerator if present. 2022-11-25 20:24:05 +00:00
Behdad Esfahbod 1d474194f0 [subset-cff] Micro-optimize encode_str 2022-11-25 13:21:35 -07:00
Behdad Esfahbod 3c4a610b59 [subset-cff] Micro-optimize copy_str some more 2022-11-25 13:16:30 -07:00