Important LOH allocations

Description

While chasing GC spikes in my application that seemed to be caused by LOH allocations, I was able that 96% was coming from the Cassandra driver.

Looking at the size of the allocations they seem to be around ~190K for OutputRows.GetBuffer.

100K to 1M for LZ4Decompressor.Decompress

and 100K to 600K for Utils.ReadAllBytes.

I suppose this only happens when the number of rows fetched is high but actually since the result is paginated and the rows are lazily iterated, I’m not expecting any large allocation.

The LZ4 decompression should be streamable. Not sure how the allocation in OutputRows.GetBuffer can be fixed though.

Environment

  • CassandraCSharpDriver 3.19.3

  • .NET 6.0

  • Linux

Attachments

3

Activity

Show:

Details

Assignee

Reporter

Priority

Created February 1, 2024 at 1:43 AM
Updated February 1, 2024 at 1:43 AM