Closed leonardt closed 6 years ago
@phanrahan Updated the top issue here to reflect our discussion this morning w.r.t. the naming conventions and interface for defining/instancing/wiring up circuits. Let me know if there's anything I missed or messed up.
I believe this is mostly done in mantle, and #73 covers the coreir primitive so I will close this for now. We can open up more specific issues related to this.
Begin with two abstract inputs:
Pattern 1:
DefineName(args)
defines a circuit, which can be instanced and wired up normallyPattern 2:
Name(args)
defines or retrieves a cached definition of the circuit and instances itPattern 3:
name(args)
infers the widths of the inputs, defines or retrieves a cached definition of the circuit, instances it, wires up inputs, and returns output