Skip to content

Lots of allocatable memory results in no buffering in SortingCollection #1741

@cmnbroad

Description

@cmnbroad

If you have many gigabytes of allocatable memory (ie., I have 32g ram, 8g is allocatable), and only a few files (say, 2), this line of code produces a negative number due to integer overflow, which incorrectly turns off buffering:

https://github.com/samtools/htsjdk/blob/master/src/main/java/htsjdk/samtools/util/SortingCollection.java#L538

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions