NonContiguousMemoryStream

An implemenation of System.IO.MemoryStream that does not use the large heap.
Download

NonContiguousMemoryStream Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Freeware
  • Publisher Name:
  • Blue Onion Software
  • Operating Systems:
  • Windows All
  • File Size:
  • 10 KB

NonContiguousMemoryStream Tags


NonContiguousMemoryStream Description

MemoryStreams are darn handy little buggers for caching away results from serialization and file copy operations. However, there's a dark side in that MemoryStreams can create additional memory pressure, particularly when stream sizes grow in excess of about 85K. At that point, the .NET runtime allocates from the large memory heap. This heap does not compact like the small memory heap and can lead to fragmentation. Often, this can cause OutOfMemoryExceptions long before physical memory is exhausted. No amount of garbage collection will reclaim this memory due to a quirk in the .NET memory management. The NonContiguousMemoryStream was designed to provide a memory store made of smaller buffers.Since the large heap is never touched, the runtime can do a better job of compacting and reclaiming memory. Requirements: · Visual Studio 2008


NonContiguousMemoryStream Related Software