Details
-
Suggestion
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
None
-
None
Description
In qharfbuzzng.cpp's _hb_qt_reference_table(), table is always malloc()ed and returned:
https://github.com/mburakov/qt5/blob/master/qtbase/src/gui/text/qharfbuzzng.cpp#L626
This is not ideal. Since the font is already mapped or otherwise available to the process, Qt should embrace that and return a hb_blob_t without a copy. That's currently not possible because Qt's get_font_table does not allow that. But there's no reason why this can't change internally.
I personally suggest acknowledging HarfBuzz as the sole shaper and exposing its types in the API. But that's me only.
Anyway. This was brought to my attention by way of the memory usage of a text layout server using Qt. Here's an older doc about HarfBuzz memory consumption:
In short, HarfBuzz should never show up as a memory hog.