Skip to content

Address fragmentation issue caused by andNot method #76

@lemire

Description

@lemire

In some cases, the andNot function can cause fragmentation: the insertion of zero literal words inside the bitmap. One can produce it with the following code:

        EWAHCompressedBitmap one = new EWAHCompressedBitmap();
        EWAHCompressedBitmap other = new EWAHCompressedBitmap();
        one.set(16627);
        other.set(52811);
        other = other.and(one);
        one = one.andNot(other);
        one.set(16039);
        other.set(78669);
        other = other.or(one);
        one = one.and(other);
        other = other.andNot(one);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions