Hypex.Register.Map (Hypex v2.1.0)
View SourceA Hypex.Register implementation using a Map.
Maps offer sparse register storage, leading to efficient memory usage. The
quick access time leaves them well suited to both read and write use cases,
but they don't scale as well as Hypex.Register.Array to higher cardinality.
Recommended for lower cardinality use cases, or when memory is more important.
Summary
Functions
Retrieve a specific bit from a register.
Initialize an empty array register of a given width.
Merge together two registers of the same width and type.
Set a specific bit in a register.
Run a reduction over the inner bits of a register.
Types
@type t() :: map()
Functions
Retrieve a specific bit from a register.
Initialize an empty array register of a given width.
Merge together two registers of the same width and type.
Set a specific bit in a register.
@spec reduce(t(), width :: number(), accumulator :: any(), (number(), any() -> any())) :: accumulator :: any()
Run a reduction over the inner bits of a register.