Module Bits.Mutable

Mutable is a mutable bits used by Cyclesim for efficiency.

type t = private Base.bytes
val empty : t
val width : t -> Base.int
val to_string : t -> Base.string
val create : Base.int -> t

Create a t of given width, initially set to 0.

val copy : src:t -> dst:t -> Base.unit
val copy_bits : src:t -> dst:t -> Base.unit
val num_words : t -> Base.int

A Bits.Mutable.t can be accessed as an array of 64 bit words.

val unsafe_get_int64 : t -> Base.int -> Base.int64
val unsafe_set_int64 : t -> Base.int -> Base.int64 -> Base.unit
val to_bits : t -> t
val of_constant : Constant.t -> t
val to_constant : t -> Constant.t
val vdd : t
val gnd : t
val wire : Base.int -> t
val (--) : t -> Base.string -> t
val (&:) : t -> t -> t -> Base.unit
val (|:) : t -> t -> t -> Base.unit
val (^:) : t -> t -> t -> Base.unit
val (~:) : t -> t -> Base.unit
val (+:) : t -> t -> t -> Base.unit
val (-:) : t -> t -> t -> Base.unit
val (==:) : t -> t -> t -> Base.unit
val (<>:) : t -> t -> t -> Base.unit
val (<:) : t -> t -> t -> Base.unit
val mux : t -> t -> t Base.list -> Base.unit
val concat : t -> t Base.list -> Base.unit
val concat_rev_array : t -> t Base.array -> Base.unit
val select : t -> t -> Base.int -> Base.int -> Base.unit
val (*:) : t -> t -> t -> Base.unit
val (*+) : t -> t -> t -> Base.unit
val mask : t -> Base.unit

Mask the unused bits to zero.

module Comb : Comb.S with type t = t