| <?xml version="1.0"?> |
| <!-- |
| Convert "implicit" parent specification for interconnect tags. |
| |
| Convert |
| <interconnect><direct><port type='input' ...><port type='output' ...></direct><YYY../></interconnect> |
| to |
| <interconnect><direct input='...' name='xxx-xxx' output='...'><YYY../></direct></interconnect> |
| |
| Convert |
| <interconnect><mux><port type='input' ...><port type='input' ...><port type='output' ...></mux><YYY../></interconnect> |
| to |
| <interconnect><mux input='in1 in2' name='xxx-xxx' output='...'><YYY../></mux></interconnect> |
| |
| This example below is connected as follows; |
| ┌───────────────────────────────────────────────────────────────────┐ |
| │ │ |
| │ ┌────────────┐ │ |
| ia1│──────>│i1 │ │ |
| │ │ │ │ |
| │ │ childa o│─┬───────────────────────────────────────────>│o0 |
| ia2│──>│╲ │ │ │ │ |
| │ │├─>│i2 │ │ │ |
| ia3│──>│╱ └────────────┘ │ ┌──────────┐ │ |
| │ ├─>│i childb o│─┬──>│╲ │ |
| │ │ └──────────┘ │ ││ ┌──────────┐ │ |
| │ │ │ │├──>│i childc o│──>│╲ │ |
| │ ├──────────────────>││ └──────────┘ ││ │ |
| │ │ │ │╱ ││ │ |
| │ │ │ ╭────────>│├──>│o1 |
| │ │ ╰─────────────╯ ││ │ |
| │ │ ││ │ |
| │ ╰──────────────────────────────────────>│/ │ |
| │ │ |
| └───────────────────────────────────────────────────────────────────┘ |
| --> |
| <xml> |
| <pb_type name="parent"> |
| <input name="ia1"/> |
| <input name="ia2"/> |
| <input name="ia3"/> |
| <output name="o0"/> |
| <output name="o1"/> |
| <pb_type name="childa"> |
| <input name="i1"/> |
| <input name="i2"/> |
| <output name="o"/> |
| </pb_type> |
| <pb_type name="childb"> |
| <input name="i"/> |
| <output name="o"/> |
| </pb_type> |
| <pb_type name="childc"> |
| <input name="i"/> |
| <output name="o"/> |
| </pb_type> |
| <interconnect> |
| <!-- Direct parent -> child --> |
| <direct> |
| <port type="input" name="ia1" /> |
| <port type="output" from="childa" name="i1" /> |
| </direct> |
| <!-- Mux parent -> child --> |
| <mux name="childa-input-i2"> |
| <port type="input" name="ia2" /> |
| <port type="input" name="ia3" /> |
| <port type="output" from="childa" name="i2" /> |
| </mux> |
| <!-- Direct parent -> child --> |
| <direct> |
| <port type="input" from="childa" name="o" /> |
| <port type="output" name="o0" /> |
| </direct> |
| <!-- Direct child -> child --> |
| <direct> |
| <port type="input" from="childa" name="o" /> |
| <port type="output" from="childb" name="i" /> |
| </direct> |
| <!-- Mux child -> child --> |
| <mux name="childc-input"> |
| <port type="input" from="childa" name="o" /> |
| <port type="input" from="childb" name="o" /> |
| <port type="output" from="childc" name="i" /> |
| </mux> |
| <!-- Mux child -> parent --> |
| <mux name="output"> |
| <port type="input" from="childa" name="o" /> |
| <port type="input" from="childb" name="o" /> |
| <port type="input" from="childc" name="o" /> |
| <port type="output" name="o1" /> |
| </mux> |
| </interconnect> |
| </pb_type> |
| </xml> |
| |