* Added new interface BufferCache -- basically a memory allocator with the

option to cache a freed buffer -- and implementations
  BlockBufferCache{NoLock,Kernel}.
* ZlibPackageDataReader does now dynamically get its read and uncompress
  buffers from a provided BufferCache when needed.
* Allocating the buffers once and keeping them over the whole life time was a
  bit too memory heavy, since we create a reader for every file for which a
  vnode is created. A FS module global factory provides a buffer cache.
* Added a mutex to PackageFile::DataAccessor which guards the access to the
  data reader which isn't thread safe.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34115 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2009-11-18 15:26:11 +00:00
parent 47212dddf5
commit 4e2cd77109
15 changed files with 682 additions and 39 deletions
@@ -10,8 +10,10 @@ DEFINES += B_ENABLE_INCOMPLETE_POSIX_AT_SUPPORT ;
HAIKU_PACKAGE_FS_SOURCES =
BlockBufferCacheKernel.cpp
DebugSupport.cpp
Directory.cpp
GlobalFactory.cpp
kernel_interface.cpp
LeafNode.cpp
Node.cpp
@@ -26,6 +28,8 @@ HAIKU_PACKAGE_FS_SOURCES =
;
HAIKU_PACKAGE_FS_PACKAGE_READER_SOURCES =
BlockBufferCache.cpp
BufferCache.cpp
DataOutput.cpp
DataReader.cpp
ErrorOutput.cpp