src/Dependencies/Collections/README.md
This package contains shared code implementing specialized collection types.
SegmentedArray<T>: This type behaves similarly to T[], but segments the underlying storage to avoid allocating arrays in the Large Object Heap. This type is most applicable in scenarios where all of the following hold:
T[]T[] (O(1) reads and writes, storage density, and/or data locality, such that tree-based data structures like ImmutableList<T> are not acceptable)AsMemory()/AsSpan() on this instance to treat it as a Memory<T>/Span<T> (this operation requires the entire array be continuous in memory)T[] in the Large Object Heap are causing performance problems that need to be addressedThe source package produced by this project may be consumed by other projects outside dotnet/roslyn.