haiku/headers/private/package
Augustin Cavalier 0ecd7516de Package Kit: Use an object_cache in kernel mode for decompression buffers.
The kernel heap only uses object caches for objects up to size 8192.
Larger allocations have to go through the raw allocator. That can
get pretty expensive.

Adding instrumentation around the malloc/free calls in this function
showed that on my machine, some 596ms during boot were spent on
*malloc/free alone*, all else aside. After this change, we are at
around 110ms, or a >5x improvement. Running an fgrep -R on /system/
after boot increased the cumulative time in memory functions to over
5 seconds, while after this change it is "only" 1170ms.

Honestly, it seems like the object depots should be able to be faster
than that, even if this function is called thousands of times. But that
is a problem for a different investigation.

It would be even faster for every consumer of this data in
packagefs just allocated one set of buffers up front, or at least
for a single "read session", but plumbing that all the way
through the myriad abstractions of the Package Kit will
not be easy, and is left for another time, as well.
2023-02-28 13:49:00 -05:00
..
hpkg Package Kit: Use an object_cache in kernel mode for decompression buffers. 2023-02-28 13:49:00 -05:00
manager Moved BJob, and JobQueue into the support kit. 2015-05-21 21:37:01 +02:00
ActivateRepositoryCacheJob.h
ActivateRepositoryConfigJob.h
ActivationTransaction.h Package Kit: Proper Installation for First Boot Packages 2021-03-14 09:10:18 +00:00
ChecksumAccessors.h
DaemonClient.h package daemon: Rework error and issue propagation to client 2014-06-15 17:21:01 +02:00
DaemonDefs.h Package Kit: Proper Installation for First Boot Packages 2021-03-14 09:10:18 +00:00
HashableString.h
packagefs.h packagefs: Extend PACKAGE_FS_OPERATION_GET_PACKAGE_INFOS ioctl 2014-04-26 15:34:18 +02:00
PackagesDirectoryDefs.h
RemoveRepositoryJob.h
TempfileManager.h
ValidateChecksumJob.h