Skip to content

Returning a Vector from GroupElement::to_bytes is slow #5

@JayPavlina

Description

@JayPavlina

Creating a vector every time GroupElement::to_bytes() is called is slow because it's allocated on the heap. It would be much faster to return a constant sized array. If the two implementations of GroupElement need to return different sized arrays, an alternative solution is to have to_bytes write to a slice that is passed in.

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