https://bugs.documentfoundation.org/show_bug.cgi?id=167455

--- Comment #12 from Patrick (volunteer) <[email protected]> ---
(In reply to Xisco FaulĂ­ from comment #11)
> (In reply to Xisco FaulĂ­ from comment #9)
> > Issue reported on harfbuzz's side:
> > https://github.com/harfbuzz/harfbuzz/issues/5386
> 
> @Patrick, I thought you might be interested in this issue since it's a mix
> of the upgrade to 11.2.0 and your patch for tdf#159529:
> https://git.libreoffice.org/core/commit/
> af47a78e11d4819bb4b1ae1a1277babd10d815b7

I got a chuckle with the "that patch dangerously modifies HarfBuzz internals".
Yes, because HarfBuzz catches every font's glyphs in memory which, on macOS,
means several gigabytes of data due to the large size of emoji and CJK fonts.
This makes HarfBuzz fast but overwhelms your average Mac.

HarfBuzz used to have a flushable cache for a font's glyphs to that
automatically repopulate its glyph cache when used again. So I am guessing
HarfBuzz now just expects  "font glyphs remain in memory for the life of the
font". Bad idea on macOS IMHO but maybe Windows and Linux fonts aren't very
large so the HarfBuzz developers don't see the memory usage as a problem.

Anyway, I think we have 2 choices here:
1. Revert my patch and watch memory usage explode for *all* macOS users (like
an extra GB or two)
2. I must write another "dangerous" modification to HarfBuzz to force a font to
repopulate its glyph cache after it has been flushed.

Thoughts?

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to