Skip to content

Make slow things less slow #34

@treeowl

Description

@treeowl

It's a bit annoying that drop and append allocate intermediate lists of individual elements. We can break up a vector (or part of one) into a type like this:

data Blobs a
  = ConsBlob !(Array a) (Blobs a)
  | EndBlobs ![a]

Now we can walk a Blobs list two chunks at a time to realign it. This is expensive, but it should be much less expensive than working through lists of elements.

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