Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
language:langs:start [2020/04/29 16:53] – [CMOS implementation] rajit | language:langs:start [2022/07/11 11:43] (current) – [Auxillary sub-languages] rajit | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Hardware description and specification languages ====== | ====== Hardware description and specification languages ====== | ||
- | ACT permits the specification and description of circuits at multiple levels of abstraction. These languages are embedded into ACT as //sublanguages//. | + | ACT permits the specification and description of circuits at multiple levels of abstraction. These languages are embedded into ACT as //sub-languages//. These sub-languages can be used to specify circuits in a variety of ways and at different levels of abstraction. Some sub-languages are only useful when combined with others. |
+ | ===== Sub-languages to specify circuits ===== | ||
- | ===== The prs sublanguage ===== | + | ACT has the following four sub-languages that are used to specify circuits: |
- | The '' | + | * [[chp|Communicating hardware processes]]: |
+ | * [[dflow|Dataflow]]: | ||
+ | * [[hse|Handshaking expansions]]: | ||
+ | * [[prs|Production rules]]: gate-level and transistor-level circuit specification | ||
- | < | ||
- | a -> b- | ||
- | ~a -> b+ | ||
- | </ | ||
- | The left-hand side of a production rule is a Boolean expression, and the right hand side specifies | + | When simulating |
- | < | + | The CHP sub-language is used to describe the circuits using a programming notation. The HSE sub-language operates on Boolean-valued variables, and has syntax similar to the CHP block. A process can have at most one CHP block and at most one HSE block; if multiple blocks of the same type are detected, an error will be flagged. |
- | bool a, b; | + | |
- | prs { | + | |
- | a -> b- | + | |
- | ~a -> b+ | + | |
- | } | + | |
- | </ | + | |
- | A two-input NAND gate with inputs '' | + | The dataflow sub-language can be used to specify computations as a static dataflow graph. The PRS sub-language can be used to specify gates as well as transistor-level implementations of circuits. These blocks can be repeated in a process, and the result is the concurrent composition of the blocks. |
- | < | + | When translating circuits from one level of abstraction to another (especially going down to production rules), it may be helpful to add additional levels of design hierarchy (e.g. by instantiating standard gates). To support this, ACT includes |
- | prs { | + | |
- | | + | |
- | ~a | ~b -> c+ | + | |
- | } | + | |
- | </ | + | |
- | A two-input inverting C-element would be: | + | * [[refine|Refinement]]: |
- | < | + | The refinement body is simply |
- | prs { | + | |
- | | + | |
- | ~a & ~b -> c+ | + | |
- | } | + | |
- | </ | + | |
- | Note that the expressive power of production rules makes it equally easy to specify state-holding gates (like an inverting C-element) and combinational gates (like a NAND gate). | + | ===== Auxiliary sub-languages ===== |
+ | Auxiliary sub-languages augment the circuit specification in some way. The sizing sub-language can be used to specify gate sizing directives that apply to the '' | ||
- | ==== The three types of arrows ==== | + | * [[sizing|Gate sizing directives]] |
+ | * [[spec|Specifications]] | ||
- | The syntax above is sufficient to be able to specify the Boolean conditions for arbitrary pull-up and pull-down networks, and uses a " | + | ===== Selecting sub-language |
- | The first common case is a combinational gate like an inverter or NAND. In a combinational gate, the Boolean | + | There are four possible levels of detail at which to model a circuit component: |
- | < | + | * CHP, where channels and full expression syntax is permitted |
- | prs { | + | * HSE, where sequencing can be specified, but all variables are Boolean-valued |
- | a & b => c- | + | * PRS, which corresponds to individual |
- | } | + | * device, which corresponds to the transistor-level implementation of the gates. The device level doesn' |
- | </ | + | |
- | Note that this is the same as specifying | + | A configuration file can be specified |
- | < | + | |
- | prs { | + | |
- | ~a | ~b => c+ | + | |
- | } | + | |
- | </code> | + | |
- | In both cases, ACT generates the second production rule from the first one by complementing the Boolean expression and changing the direction of the signal transition ('' | ||
- | |||
- | The second common case is that of C-elements. To specify the two-input C-element above, you can also write | ||
< | < | ||
- | prs { | + | begin level |
- | a & b #> c- | + | # valid strings are " |
- | } | + | string default " |
- | </ | + | end |
- | In this case, ACT generates | + | </ |
- | ==== Loops ==== | + | This specifies |
- | + | ||
- | When defining parameterized circuits, it is helpful to also have the corresponding parametrized production rules that implement the circuit. There are two loop constructs available that use the same " | + | |
< | < | ||
- | bool x[5], y[5]; | + | begin level |
- | + | begin types | |
- | prs { | + | # chp process model |
- | (i:5: x[i] => y[i]-) | + | string_table chp " |
- | } | + | # prs process model |
+ | | ||
+ | end | ||
+ | end | ||
</ | </ | ||
- | + | This specifies | |
- | The example above creates five inverters when the circuit is expanded. '' | + | |
- | + | ||
- | < | + | |
- | bool x[5], y; | + | |
- | + | ||
- | prs { | + | |
- | (&i:5: x[i]) => y- | + | |
- | } | + | |
- | </ | + | |
- | + | ||
- | The example above is a 5-input NAND gate. Here the replication construct is used with ''&'' | + | |
- | + | ||
- | < | + | |
- | ... | + | |
- | prs { | + | |
- | x[0] & x[1] & x[2] & x[3] & x[4] => y- | + | |
- | } | + | |
- | </ | + | |
- | + | ||
- | Similarly, '' | + | |
- | + | ||
- | < | + | |
- | prs { | + | |
- | en & (|i:5: x[i]) -> y- | + | |
- | ~en -> y+ | + | |
- | } | + | |
- | </ | + | |
- | + | ||
- | ==== CMOS implementation ==== | + | |
- | + | ||
- | The ACT tools provide automated support for converting production rules into a transistor-level implementation. | + | |
- | + | ||
- | === Implementable rules === | + | |
- | + | ||
- | In what follows, we assume that the production rule expression is written in negation-normal form((Negation-normal form for a Boolean expression corresponds to a Boolean expression where the negation symbol can only appear on a variable. In other words, an expression like '' | + | |
- | + | ||
- | For a production rule to be // | + | |
- | < | + | |
- | a & b -> c+ | + | |
- | a & b -> d- | + | |
- | ~a | ~b -> e+ | + | |
- | </ | + | |
- | + | ||
- | === Transistor sizing and flavors === | + | |
- | + | ||
- | The width, length, flavor, and folding of a transistor can be specified | + | |
- | < | + | |
- | a <10> & b <10> -> c- | + | |
- | </ | + | |
- | In this example, the widths of the transistor for '' | + | |
- | + | ||
- | < | + | |
- | a < | + | |
- | </ | + | |
- | In this example, the transistor specified is one with a width of 20 units and length of 4 units. The default values of width and length for p-type and n-type devices are specified in the [[config: | + | |
- | + | ||
- | < | + | |
- | a < | + | |
- | </ | + | |
- | Transistors come in different //flavors// in a modern technology. The flavors supported by ACT are specified in the top-level ACT [[config: | + | |
- | + | ||
- | Finally, it is often the case that multiple transistors in an expression use the same sizing information. | + | |
- | < | + | |
- | a <10> & b -> c- | + | |
- | </ | + | |
- | In this example, the sizing for '' | + | |
- | + | ||
- | === Gate ordering === | + | |
- | + | ||
- | A rule of the form | + | |
- | < | + | |
- | a & b -> c- | + | |
- | </ | + | |
- | it could be implemented with a series transistor chain. However, if the gates of the two series transistors are exchanged, the Boolean expression is still logically the same value although the circuit characteristics (e.g. delay) might be different. | + | |
- | + | ||
- | ACT imposes a strict interpretation on gate ordering, since a circuit designer might have carefully chosen the gate ordering for their circuit. The interpretation is that, since the output is on the right hand side of the production rule, the gate closest to the output corresponds to the rightmost variable. So, in the example above, the gate order would be that '' | + | |
- | + | ||
- | === Multi-finger transistors === | + | |
- | + | ||
- | A multi-fingered transistor can be manually specified if necessary. The example | + | |
- | < | + | |
- | (a <10> | a< | + | |
- | </ | + | |
- | would have the effect of using two multi-fingered transistors, | + | |
- | < | + | |
- | a< | + | |
- | </ | + | |
- | or, using the implicit sizing rules, as | + | |
- | < | + | |
- | | + | |
- | </ | + | |
- | + | ||
- | + | ||