[Rpm-maint] [rpm-software-management/rpm] Rust bindings for rpmlib (#429)
Jeff Johnson
notifications at github.com
Sat Apr 14 17:05:39 UTC 2018
There are 3-4 levels of memory usage with header tag data using MINMEM:
1) the rpmtd container with malloc/free, non-refcounted
2) (string arrays only) the array of pointers to strings, free'd on release
3) the data, protected by the header ref count
4) (if used) string pools to memoize/uniqify tag data
Simplest approach is not to use data outside of the narrow access window: always copy.
Not using MINMEM is another approach.
(aside)
Disclaimer: I've only a little bit of experience with rpmtd memory usage, none with string pools. I chose a different/simpler approach ("Always malloc tag data") to solve identical issues as MINMEM and rpmtd solve in RPM4.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/429#issuecomment-381343922
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20180414/5320fa74/attachment.html>
More information about the Rpm-maint
mailing list