Chip design · open-source flow

apb_uart_sv

A 16550-style UART verified with pyuvm: APB agent, scoreboard and a SystemRDL register model, on RTL and gates, to GDS.

Built 2026-10-11 12:54 (UTC+8) · anlit75/c4o-pyuvm · commit 1a5d71a · CI run

6/6 on RTL6/6 on gates12/12 regression runs
Timing metSignoff clean

View sourceGDS · 4.0 MB

Layout of apb_uart_sv
236.6 × 247.3 µm · 2,978 instances after routing · sky130A

Summary

die
236.6 × 247.3 µm
58,518.3 µm²
core utilization
51.0%
of a 225.4 × 223.0 µm core
instances
2,978
after routing, 1,411 after synthesis
clock
91 MHz
11 ns period
timing, worst slack
+2.57 ns
setup · 0 violations
+0.04 ns
hold · 0 violations
code coverage
79.2%
Block
73.0%
Branch
61.0%
Toggle
total power
3.448 mW
typical wire RC, typical transistors, 25 °C, 1.80 V
signoff
clean
DRC, LVS, antenna, XOR

Files: metrics.json 17.5 kB · history.json 1.6 kB

Tests: 6/6 on RTL, 6/6 on gates

The same cocotb tests, on the RTL and on the synthesized netlist with the PDK cell models.

Seeds: RTL 1791694078 · gates 1791694402. Each seed reruns its run exactly.

testRTLgates
reset_valuesPASSPASS
register_readbackPASSPASS
idle_statusPASSPASS
loopbackPASSPASS
random_bytesPASSPASS
burstPASSPASS
History (3 commits)
RTL passed
  • passed
  • total
062.25.02.27.0afb5946: total 62a4a47a: total 61a5d71a: total 6afb5946: passed 62a4a47a: passed 61a5d71a: passed 6afb59461a5d71a
Gate level passed
  • passed
  • total
062.25.02.27.0afb5946: total 62a4a47a: total 61a5d71a: total 6afb5946: passed 62a4a47a: passed 61a5d71a: passed 6afb59461a5d71a

Files: cocotb-results.xml 1.3 kB · cocotb-gl-results.xml 1.3 kB

Regression: 12/12 runs passed

Each row is a module of the test list, run once for each of its seeds. Under it are the tests it holds.

Base seed 19193966. make regress SEED=19193966 reruns the list with the same seeds.

module and its testsseedsruns passed
test_uart.random_bytes
  • random_bytes
1010/10
test_uart
  • loopback
  • random_bytes
  • burst
11/1
test_ral
  • reset_values
  • register_readback
  • idle_status
11/1
History (3 commits)
Runs passed
  • passed
  • total
0122.25.02.27.0afb5946: total 122a4a47a: total 121a5d71a: total 12afb5946: passed 122a4a47a: passed 121a5d71a: passed 12afb59461a5d71a

Files: regress-summary.json 1.3 kB

Coverage

Code coverage of the RTL, from the 12 runs of Regression, run again under Verilator and merged.

kindcoveredshare
Block80 / 10179.2%
Branch92 / 12673.0%
Toggle584 / 95861.0%

Not measured: expression and FSM coverage. The Verilator in the image does not support them.

Coverage by module (6)
moduleblockbranchtoggle
apb_uart_sv86.7%77.8%35.0%
io_generic_fifo__D8_B10100.0%100.0%83.2%
io_generic_fifo__D9_B10100.0%100.0%73.6%
uart_interrupt__T10_R1050.0%50.0%52.6%
uart_rx75.8%65.6%68.1%
uart_tx73.7%70.6%67.8%
History (3 commits)
Coverage (%)
  • Block
  • Branch
  • Toggle
01002.25.02.27.0afb5946: Block 79.2%2a4a47a: Block 79.2%1a5d71a: Block 79.2%afb5946: Branch 73.0%2a4a47a: Branch 73.0%1a5d71a: Branch 73.0%afb5946: Toggle 61.0%2a4a47a: Toggle 61.0%1a5d71a: Toggle 61.0%afb59461a5d71a

Files: coverage-summary.json 9.8 kB

Timing

Timing is met: no setup or hold slack is negative.

Worst slack after routing, over every corner the flow analysed.

checkworst slackviolationsreg-to-reg
setup+2.57 ns0+2.74 ns
hold+0.04 ns0+0.11 ns

Slew, capacitance and fanout limits

Design rule violations after routing, against the limits in the run's constraints. They are warnings: the flow does not stop on them, and the timing verdict above leaves them out.

limitviolationscorners
max slew9max_ss_100C_1v60, nom_ss_100C_1v60
max capacitance0none
max fanout10max_ff_n40C_1v95, max_ss_100C_1v60, max_tt_025C_1v80, min_ff_n40C_1v95, min_ss_100C_1v60, min_tt_025C_1v80, nom_ff_n40C_1v95, nom_ss_100C_1v60, nom_tt_025C_1v80
Constraints the run used (5)

From the post-route timing step. The slack above holds only for these values.

constraintvaluesource
clock period11 ns (91 MHz)set in config.yaml
clock uncertainty0.25 nsflow default
clock transition0.15 nsflow default
timing derate5%flow default
input and output delay5% of the clock period (0.55 ns)set in config.yaml
History (3 commits)
Setup WS (ns)
02.572.25.02.27.0afb5946: +2.57 ns2a4a47a: +2.57 ns1a5d71a: +2.57 nsafb59461a5d71a
Hold WS (ns)
00.042.25.02.27.0afb5946: +0.04 ns2a4a47a: +0.04 ns1a5d71a: +0.04 nsafb59461a5d71a

Files: apb_uart_sv.sdc 17.2 kB

Area and Instances

Standard cell library sky130_fd_sc_hd, single threshold voltage.

Synthesis produced 20,352.0 µm² of instances. Place and route grew it by 26% to 25,629.6 µm².

Instances: 1,411 after synthesis, 2,978 after routing

Placed instances, by LibreLane class. Fill is not counted.

Drive strength of the instances (6 sizes)

Well taps, decap, fill and antenna diodes have no drive strength and are not counted.

drive strengthafter synthesisafter routing
X1353961
X21,0581,198
X4018
X6019
X8056
X1609
Total1,4112,261

Place and route added 608 X1, 140 X2, 56 X8, 19 X6, 18 X4 and 9 X16 instances.

History (3 commits)
Area (µm²)
  • flip-flops
  • combinational logic
  • added by place and route
025,6302.25.02.27.0afb5946: flip-flops 10,405.0 µm²; combinational logic 9,947.0 µm²; added or resized by place and route 5,277.6 µm² (total 25,629.6 µm²)2a4a47a: flip-flops 10,405.0 µm²; combinational logic 9,947.0 µm²; added or resized by place and route 5,277.6 µm² (total 25,629.6 µm²)1a5d71a: flip-flops 10,405.0 µm²; combinational logic 9,947.0 µm²; added or resized by place and route 5,277.6 µm² (total 25,629.6 µm²)afb59461a5d71a
Instances
  • from synthesis
  • added by the flow
02,9782.25.02.27.0afb5946: from synthesis 1,411; added by the flow 1,567 (total 2,978)2a4a47a: from synthesis 1,411; added by the flow 1,567 (total 2,978)1a5d71a: from synthesis 1,411; added by the flow 1,567 (total 2,978)afb59461a5d71a

Files: apb_uart_sv.nl.v 460.6 kB

Power

3.448 mW in total at corner nom_tt_025C_1v80 (typical wire RC, typical transistors, 25 °C, 1.80 V), clock 91 MHz. The table is in µW.

Switching activity is OpenSTA's default, 0.1 toggles per clock on data nets. It is not taken from simulation, so this estimates where power goes. It does not measure a workload.

groupinternalswitchingleakagetotalshare
Sequential1,558.0123.7<0.11,681.748.8%
Combinational314.1300.5<0.1614.617.8%
Clock609.2542.5<0.11,151.733.4%
Total2,481.3966.6<0.13,448.0100.0%

Static IR drop, worst: 0.52 mV, 0.029% of 1.80 V, from OpenROAD (ir__drop__worst).

History (3 commits)
Total power (mW)
03.4482.25.02.27.0afb5946: 3.448 mW2a4a47a: 3.448 mW1a5d71a: 3.448 mWafb59461a5d71a
Static IR drop, worst (% of supply)
00.0292.25.02.27.0afb5946: 0.029%2a4a47a: 0.029%1a5d71a: 0.029%afb59461a5d71a

Signoff checks

The DRC row adds the errors of both tools.

checkerrorsresult
DRC Magic and KLayout0PASS
LVS0PASS
antenna checked by OpenROAD, not by DRC0PASS
XOR Magic GDS against KLayout GDS0PASS

Not analysed: electromigration, crosstalk and dynamic IR drop.

How it was built

One picture per stage of the real run, which took 4 min 14 s.

Floorplan: layout at the end of the stage
  • Synthesisno picture7.8 s

    RTL becomes gates; lint and a first timing check
    Your Verilog is checked, then turned into logic gates from the Sky130 cell library. There is no layout yet, so this stage has no picture.

  • Floorplan4.0 s

    pick the die size, power grid and tap cells
    The die is the outline of the chip. The empty rows are where gates will sit, and the stripes are the metal rails that bring power to them.

  • Placement14 s

    give every gate a place on the die
    Every gate now has a place on the die. The small colored blocks are the cells, packed into the rows.

  • Clock tree29 s

    build the clock distribution and fix its timing
    Extra buffers now carry the clock to every flip-flop at nearly the same moment. They are small cells added among the others.

  • Routing2 min 15 s

    draw the wires; repair antenna violations
    Metal wires now connect the gates. The colored lines drawn over the cells are wires on different metal layers.

  • Finish & GDS26 s

    fill, extract parasitics, final timing, write the GDS
    Filler cells close the gaps between the gates, and timing is measured again from the real wires. The picture is the layout that is written to the GDS file.

  • Signoff39 s

    DRC, LVS, antenna, XOR: can it be made?
    The checks a fab would run on the finished layout. This is the picture of that layout, the one that is handed over.

Files: floorplan.png 61.7 kB · placement.png 145.6 kB · clock-tree.png 153.9 kB · routing.png 295.1 kB · finish-gds.png 279.4 kB