Commit Graph
18183 Commits
Author SHA1 Message Date
Behdad Esfahbod a2fc952342 [hvgl] Use a common "scratch" vector
To avoid reallocation.
2025-03-02 16:57:55 -07:00
Behdad Esfahbod de0e1bddff [hvgl] Minor simplify sanitize 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 4e56a0b8b5 [hvgl] Use smarter algorithm for cycle detection
Great speedup as we don't use hb_set_t. Yay!
2025-03-02 16:57:55 -07:00
Behdad Esfahbod cd73ca3c24 [hvgl] Possibly save a malloc 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 7a171dcca9 [hvgl] Simplify resize call 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 60562fce1a [hvgl] Remove an unnecessary cast 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 26fc2d7c83 [hvgl] Minor var type declaration 2025-03-02 16:57:55 -07:00
Behdad Esfahbod fc62af31c3 [hvgl] Bail on error
Easier than handling a vector too short.
2025-03-02 16:57:55 -07:00
Behdad Esfahbod 2a3477c87f [hvgl] Micro-optimize 2025-03-02 16:57:55 -07:00
Behdad Esfahbod d9d589583f [geometry] Minor avoid a default initialization
Compiler probably doesn't care though.
2025-03-02 16:57:55 -07:00
Behdad Esfahbod 7d3b340d2c [hvgl] Grammar 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 241304b2ca [hvgl] Micro-optimize 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 460f0f1996 [hvgl] Cosmetic 2025-03-02 16:57:55 -07:00
Behdad Esfahbod b191d08450 [hvgl] Micro-optimize 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 500290bb4d [hvgl] Fix typo 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 3bdae43ac6 [hvgl] Add a barrier
Just in case.
2025-03-02 16:57:55 -07:00
Behdad Esfahbod c52c98abd3 [hvgl] Remove a duplicate variable 2025-03-02 16:57:55 -07:00
Behdad Esfahbod 0a25471bdf [hvgl] Fix vector resize
I meant to resize to exact, but the false wasn't doing that.
2025-03-02 16:57:55 -07:00
Behdad Esfahbod 4bced20619 [hvgl] Rename a method 2025-03-02 16:57:55 -07:00
Behdad Esfahbod ecc5800a0e [hvgl] Simplify an array access 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 3f9e9b0b5f [hvgl] Speed up a loop 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 42b562997d [hvgl] Simplify a bit 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 79fba6e011 [hvgl] Comment 2025-03-02 16:57:54 -07:00
Behdad Esfahbod ea50fa2893 [hvgl] Remove commented out leftover 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 5fa2c628ac [hvgl] Avoid a div-by-zero 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 1b42d811a0 [hvgl] Micro-optimize segment access 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 3a6dc3d2d1 [hvgl] Micro-optimize 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 6e92267c96 [hvgl] Only pass the needed coords around 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 80a8c5fa3c [hvgl] Whitespace 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 4fc694185a [hvgl] Rename "be" var to "le" 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 303cd634f3 [hvgl] Disable unnecessary code 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 9c788d12f1 [hvgl] Comment 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 3d0fae3f5f [hvgl] Optimize initial getting of coordinates 2025-03-02 16:57:54 -07:00
Behdad Esfahbod f31fa0ae9b [hvgl] Optimize extremum transforms some more
Passed the 2x threshold, faster than CoreText.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod e7a05b1b6f [hvgl] Micro-optimize 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 4ba069257d [hvgl] Minor use a variable 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 727b647e1f [hvgl] Speed up transform variations 2025-03-02 16:57:54 -07:00
Behdad Esfahbod be30bf9d74 [hvgl] Simplify master transforms a bit more 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 93ddf8f8af [hvgl] Move variables around 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 49fd66eb4b [hvgl] Split apply_transforms into two loops
The paper says walk them together, but the master can be applied
separately before the extremums.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod 19114e0c0e [hvgl] Micro-optimize transforms
Measurable speedup.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod b7a9f15d54 [hvgl] Simplify transforms
Speeds up a bit too.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod 3a8d6d60ee [hvgl] Iterate all four iterators together
Instead of trying every row, sparsely process non-trivial rows.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod a1fba4ebd4 [hvgl] Micro-optimize 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 8f505a70e3 [hvgl] Speed up simd path
Only process coord!=0 columns.

For some reason I don't see any speedup :-(.
2025-03-02 16:57:54 -07:00
Behdad Esfahbod c111f088cf [hvgl] Simplify sanitize more 2025-03-02 16:57:54 -07:00
Behdad Esfahbod d4600d8ddd [hvgl] Simplify more sanitize 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 41ee17e883 [hvgl] Simplify sanitize 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 4f3c3ee0ea [hvgl/simd] Only enable if little-endian 2025-03-02 16:57:54 -07:00
Behdad Esfahbod 8e7eeb5f7a Revert "[hvgl] Implement AVX"
This reverts commit 82ac479cbb49a88946025be2b84315bfd6091d24.
2025-03-02 16:57:54 -07:00