Skip to content

Use smaller limb size for small stints #146

@arnetheduck

Description

@arnetheduck

https://github.com/status-im/nim-stint/blob/master/stint/private/datatypes.nim#L16C8-L16C8 - currently, Word is used for all stint sizes, ie Stint[16] takes 8 bytes on a 64-bit system.

With bit sizes less than the Word size, we should be using the next-power-of-2 approach, ie both stint[15] and stint[16] should take up 2 bytes of space like an int16.

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