Holds the state of the circuit at a particular time State is kept for input, output and registers
Holds the state of the circuit at a particular time State is kept for input, output and registers
a map to current concrete value
a map to current concrete value
a map to current concrete value
A runtime instance of a SInt
A runtime instance of a SInt
the BigInt value of this UInt,
the number of bits in this value, must be big enough to contain value plus 1 for sign bit
A runtime instance of a UInt
A runtime instance of a UInt
the BigInt value of this UInt, must be non-negative
the number of bits in this value, must be big enough to contain value
A (probably overly complex) map of the names to expressions that occur in @circuit This is used by the expression evaluator to follow dependencies It also maintains lists or sets of ports, registers, memories, stop and printf statements.
A (probably overly complex) map of the names to expressions that occur in @circuit This is used by the expression evaluator to follow dependencies It also maintains lists or sets of ports, registers, memories, stop and printf statements. The above information is created by the companion object which does the actual work of traversing the circuit and discovering the various components and expressions
This is the Firrtl interpreter.
This is the Firrtl interpreter. It is the top level control engine that controls the simulation of a circuit running.
It coordinates updating of the circuit's inputs (other elements, nodes, registers, etc can be forced to values) and querying the circuits outputs (or optionally other circuit components)
This mainly involves updating of a circuit state instance by using a expression evaluator on a dependency graph.
Created by chick on 4/21/16.
Works a lot like the chisel classic tester compiles a firrtl input string and allows poke, peek, expect and step
Works a lot like the chisel classic tester compiles a firrtl input string and allows poke, peek, expect and step
pokes invalidate the underlying circuit peek, expect and step, recompute (re-validate) the circuit before executing
Important note: port names in LoFirrtl have replaced dot notation with underscore notation so that io.a.b must be referenced as io_a_b
This is the evaluation engine for the FirrtlTerp it requires the previousState of the system
provides a black box implementation of a circuit memory presenting read, write and read/write interfaces
provides a black box implementation of a circuit memory presenting read, write and read/write interfaces
Assumptions: Zero read_latency latches data straight to memory(address): IGNORES enable
contains the constructor for a dependency graph.
contains the constructor for a dependency graph. The code for traversing a circuit and discovering the components and the expressions lives here
Created by chick on 4/21/16.
Utility function that computes bits required for a number
Utility function that computes bits required for a number
number of interest
computes the smallest and largest values that will fit in an SInt
computes the smallest and largest values that will fit in an SInt
width of SInt
tuple(minVale, maxValue)
computes the smallest and largest values that will fit in a UInt
computes the smallest and largest values that will fit in a UInt
width of SInt
tuple(minVale, maxValue)
return the smallest number of bits required to hold the given number in an SInt Note: positive numbers will get one minimum width one higher than would be required for a UInt
return the smallest number of bits required to hold the given number in an SInt Note: positive numbers will get one minimum width one higher than would be required for a UInt
number to find width for
minimum required bits for an SInt
return the smallest number of bits required to hold the given number in an UInt Note: positive numbers will get one minimum width one higher than would be required for a UInt
return the smallest number of bits required to hold the given number in an UInt Note: positive numbers will get one minimum width one higher than would be required for a UInt
number to find width for
minimum required bits for an SInt