Hello,

> Are you talking about System.IO.MemoryStream?
> Then imho this would be a problematic move.
> Most people are used to new MemoryStream (someByteArray) being O(0) time,
> but with ChunkedStream would be O(n). In fact in those cases ChunkedStream
> would need twice the memory because it would still need to retain the
> original byte array (e.g. for GetBuffer).

I dont think it would be O(n), there is a dereference only.

> 
> Happy hacking
> Andreas
> 
> -----Ursprüngliche Nachricht-----
> Von: mono-devel-list-boun...@lists.ximian.com
> [mailto:mono-devel-list-boun...@lists.ximian.com] Im Auftrag von Miguel de
> Icaza
> Gesendet: Montag, 9. November 2009 19:10
> An: mono-devel-list
> Betreff: [Mono-dev] Should we replace MemoryStream?
> 
> Hello folks,
> 
>     I just blogged about a memory fragmentation issue here:
> 
>       http://tirania.org/blog/archive/2009/Nov-09.html
> 
>     And I am wondering: since MemoryStream is one of these sources of
> problems, we could replace this implementation with MindTouch's
> ChunkedStream.
> 
> Miguel.
> 
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
> 

_______________________________________________
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list

Reply via email to