Skip to content

Commit 3f20f36

Browse files
committed
workflows: change pdk to asap7
1 parent 49b4755 commit 3f20f36

File tree

6 files changed

+74
-41
lines changed

6 files changed

+74
-41
lines changed

.github/workflows/static-power-analysis-flow.yml

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
strategy:
2929
fail-fast: false
3030
matrix:
31-
os: [ubuntu-24.04]
31+
os: [ubuntu-22.04]
3232
runs-on: ${{ matrix.os }}
3333
name: Static power verilator flow | ${{ matrix.os }}
3434
env:
@@ -55,10 +55,13 @@ jobs:
5555
run: |
5656
tuttest README.md build-verilator | bash -
5757
58+
- name: Fetch asap7 sources
59+
run: git clone https://github.com/The-OpenROAD-Project/asap7sc7p5t_28
60+
5861
- name: Fetch OpenROAD-flow-scripts
5962
run: |
6063
git clone https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts
61-
cd OpenROAD-flow-scripts && git checkout d62c05a87108d1ec50945c7e8d893b58dd778094
64+
cd OpenROAD-flow-scripts && git checkout f53fbce71af0e7965b3fa76396ff6d3e8121b6bb
6265
6366
- name: Update OpenROAD ibex sources
6467
run: |
@@ -74,7 +77,7 @@ jobs:
7477
7578
- name: Copy synthesized model to the example directory
7679
run: |
77-
cp OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth_sky.v
80+
cp OpenROAD-flow-scripts/flow/results/asap7/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth.v
7881
7982
- name: Generate SAIF file from simulation trace
8083
run: |
@@ -92,8 +95,9 @@ jobs:
9295
with:
9396
name: static power analysis report
9497
path: |
95-
OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
98+
OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
9699
example/sim.saif
100+
example/ibex_simple_system.log
97101
98102
peak-power-analysis:
99103
strategy:
@@ -127,10 +131,13 @@ jobs:
127131
run: |
128132
tuttest README.md build-verilator | bash -
129133
134+
- name: Fetch asap7 sources
135+
run: git clone https://github.com/The-OpenROAD-Project/asap7sc7p5t_28
136+
130137
- name: Fetch OpenROAD-flow-scripts
131138
run: |
132139
git clone https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts
133-
cd OpenROAD-flow-scripts && git checkout d62c05a87108d1ec50945c7e8d893b58dd778094
140+
cd OpenROAD-flow-scripts && git checkout f53fbce71af0e7965b3fa76396ff6d3e8121b6bb
134141
135142
- name: Update OpenROAD ibex sources
136143
run: |
@@ -155,7 +162,7 @@ jobs:
155162
156163
- name: Copy synthesized model to the example directory
157164
run: |
158-
cp OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth_sky.v
165+
cp OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth.v
159166
160167
- name: Generate VCD file from simulation trace
161168
run: |
@@ -188,6 +195,7 @@ jobs:
188195
path: |
189196
OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
190197
example/sim.vcd
198+
example/ibex_simple_system.log
191199
192200
glitch-power-analysis:
193201
strategy:
@@ -221,10 +229,13 @@ jobs:
221229
run: |
222230
tuttest README.md build-verilator | bash -
223231
232+
- name: Fetch asap7 sources
233+
run: git clone https://github.com/The-OpenROAD-Project/asap7sc7p5t_28
234+
224235
- name: Fetch OpenROAD-flow-scripts
225236
run: |
226237
git clone https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts
227-
cd OpenROAD-flow-scripts && git checkout d62c05a87108d1ec50945c7e8d893b58dd778094
238+
cd OpenROAD-flow-scripts && git checkout f53fbce71af0e7965b3fa76396ff6d3e8121b6bb
228239
229240
- name: Update OpenROAD ibex sources
230241
run: |
@@ -249,7 +260,7 @@ jobs:
249260
250261
- name: Copy synthesized model to the example directory
251262
run: |
252-
cp OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth_sky.v
263+
cp OpenROAD-flow-scripts/flow/results/asap7/ibex/base/1_synth.v example/verilog/ibex_core/ibex_core_synth.v
253264
254265
- name: Generate VCD file from simulation trace
255266
run: |
@@ -285,4 +296,7 @@ jobs:
285296
uses: actions/[email protected]
286297
with:
287298
name: peak power with glitches analysis report
288-
path: OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
299+
path: |
300+
OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
301+
example/sim.vcd
302+
example/ibex_simple_system.log

README.md

Lines changed: 29 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export PATH=$PATH:$(pwd)/bin/
3131

3232
Remember to add the Verilator binary directory `~/dev/verilator/bin/` to the `PATH` environmental variable.
3333

34-
- [OpenROAD-flow-scripts](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts) with `Yosys` and `OpenROAD` (tested on commit `d62c05a8`). To build `Yosys` and `OpenROAD` in `OpenROAD-flow-scripts` run:
34+
- [OpenROAD-flow-scripts](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts) with `Yosys` and `OpenROAD` (tested on commit `f53fbce`). To build `Yosys` and `OpenROAD` in `OpenROAD-flow-scripts` run:
3535

3636
<!-- name="build-openroad" -->
3737
```
@@ -56,13 +56,14 @@ export PATH=$PATH:$(pwd)/target/release/
5656

5757
### Process model sources with Yosys and OpenROAD
5858

59-
For power consumption report generation you will need to prepare simulated model sources for `Yosys` synthesis and `OpenROAD` place and route step in the `OpenROAD-flow-scripts` project directory. Example workflows uses the `sky130hd` platform. Copy design contents from `example` directory to `OpenROAD-flow-scripts/flow/designs/sky130hd/ibex/` and `OpenROAD-flow-scripts/flow/designs/src/ibex`:
59+
For power consumption report generation you will need to prepare simulated model sources for `Yosys` synthesis and `OpenROAD` place and route step in the `OpenROAD-flow-scripts` project directory. Example workflows uses the `asap7` platform. Copy design contents from `example` directory to `OpenROAD-flow-scripts/flow/designs/asap7/ibex/` and `OpenROAD-flow-scripts/flow/designs/src/ibex`:
6060

6161
<!-- name="copy-model-sources" -->
6262
```
63-
cp example/design/* OpenROAD-flow-scripts/flow/designs/sky130hd/ibex/
63+
mkdir -p OpenROAD-flow-scripts/flow/designs/asap7/ibex/
64+
cp example/design/* OpenROAD-flow-scripts/flow/designs/asap7/ibex/
6465
65-
rm OpenROAD-flow-scripts/flow/designs/src/ibex/*
66+
mkdir -p OpenROAD-flow-scripts/flow/designs/src/ibex/
6667
cp example/verilog/ibex_core/* OpenROAD-flow-scripts/flow/designs/src/ibex/
6768
```
6869

@@ -71,10 +72,10 @@ Then go to the `OpenROAD-flow-scripts` project top directory and run the require
7172
<!-- name="run-synthesis-steps" -->
7273
```
7374
cd OpenROAD-flow-scripts
74-
make -C flow DESIGN_CONFIG=designs/sky130hd/ibex/config.mk route
75+
make -C flow DESIGN_CONFIG=designs/asap7/ibex/config.mk route
7576
```
7677

77-
Finally copy the result of synthesis to relevant example directory, i.e. from `~/dev/OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/1_synth.v` to `example/verilog/ibex_core/ibex_core_synth_sky.v`.
78+
Finally copy the result of synthesis to relevant example directory, i.e. from `~/dev/OpenROAD-flow-scripts/flow/results/asap7/ibex/base/1_synth.v` to `example/verilog/ibex_core/ibex_core_synth_sky.v`.
7879

7980
## Static power analysis workflow
8081

@@ -84,7 +85,7 @@ From the `example` directory, run verilation and compile the model to an executa
8485

8586
<!-- name="generate-saif-file" -->
8687
```
87-
export CELL_SOURCES=$(pwd)/OpenROAD-flow-scripts/flow/platforms/sky130hd/work_around_yosys/
88+
export CELL_SOURCES=$(pwd)/asap7sc7p5t_28/Verilog/
8889
8990
cd example/
9091
verilator --build --exe -f post_synthesis.vc --trace-saif --trace-structs --trace-params --trace-max-array 1024 \
@@ -101,30 +102,33 @@ Copy previously generated SAIF file from simulation trace and `power.tcl` comman
101102

102103
<!-- name="copy-required-artifacts" -->
103104
```
104-
cp example/sim.saif OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
105-
cp saif_example/power.tcl OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
105+
cp example/sim.saif OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
106+
cp saif_example/power.tcl OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
106107
```
107108

108109
For liberty files paths simplicity, you can export the path to their directory as the `LIB_DIR` environmental variable. In this example it will be:
109110

110111
<!-- name="export-liberty-path" -->
111112
```
112-
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/sky130hd/lib/
113+
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/asap7/lib/NLDM/
113114
```
114115

115116
Go to the synthesis results directory and then run `openroad` with commands:
116117

117118
<!-- name="execute-openroad-commands" -->
118119
```
119-
cd OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
120+
cd OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
120121
openroad power.tcl -exit
121122
```
122123

123124
or you can just execute them manually after running `openroad` in the synthesis results directory:
124125

125126
```
126-
read_liberty $::env(LIB_DIR)/sky130_dummy_io.lib
127-
read_liberty $::env(LIB_DIR)/sky130_fd_sc_hd__tt_025C_1v80.lib
127+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_AO_RVT_FF_nldm_211120.lib.gz
128+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_INVBUF_RVT_FF_nldm_220122.lib.gz
129+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_OA_RVT_FF_nldm_211120.lib.gz
130+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SIMPLE_RVT_FF_nldm_211120.lib.gz
131+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SEQ_RVT_FF_nldm_220123.lib
128132
129133
read_db 5_route.odb
130134
@@ -159,7 +163,7 @@ From the `example` directory, run verilation and compile the model to an executa
159163

160164
<!-- name="generate-vcd-file" -->
161165
```
162-
export CELL_SOURCES=$(pwd)/OpenROAD-flow-scripts/flow/platforms/sky130hd/work_around_yosys/
166+
export CELL_SOURCES=$(pwd)/asap7sc7p5t_28/Verilog/
163167
164168
cd example/
165169
verilator --build --exe -f post_synthesis.vc --trace --trace-structs --trace-params --trace-max-array 1024 \
@@ -197,23 +201,23 @@ Copy previously generated TCL files with required scripts to the synthesis resul
197201

198202
<!-- name="copy-required-peak-power-artifacts" -->
199203
```
200-
cp -r example/total_output OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
201-
cp example/base_output OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
202-
cp peak_power_example/peak_power.py OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
204+
cp -r example/total_output OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
205+
cp example/base_output OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
206+
cp peak_power_example/peak_power.py OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
203207
```
204208

205209
For liberty files paths simplicity, you can export the path to their directory as the `LIB_DIR` environmental variable. In this example it will be:
206210

207211
<!-- name="export-liberty-path" -->
208212
```
209-
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/sky130hd/lib/
213+
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/asap7/lib/NLDM/
210214
```
211215

212216
Go to the synthesis results directory and then run the peak power script:
213217

214218
<!-- name="execute-peak-power-script" -->
215219
```
216-
cd OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
220+
cd OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
217221
python3 peak_power.py --base base_output --total total_output --csv power_analysis.csv
218222
```
219223

@@ -250,24 +254,24 @@ Copy previously generated TCL files with required scripts to the synthesis resul
250254

251255
<!-- name="copy-required-glitch-power-artifacts" -->
252256
```
253-
cp -r example/total_output OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
254-
cp -r example/glitch_output OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
255-
cp example/base_output OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
256-
cp peak_power_example/peak_power.py OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
257+
cp -r example/total_output OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
258+
cp -r example/glitch_output OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
259+
cp example/base_output OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
260+
cp peak_power_example/peak_power.py OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
257261
```
258262

259263
For liberty files paths simplicity, you can export the path to their directory as the `LIB_DIR` environmental variable. In this example it will be:
260264

261265
<!-- name="export-liberty-path" -->
262266
```
263-
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/sky130hd/lib/
267+
export LIB_DIR=$(pwd)/OpenROAD-flow-scripts/flow/platforms/asap7/lib/NLDM/
264268
```
265269

266270
Go to the synthesis results directory and then run the glitch power script:
267271

268272
<!-- name="execute-glitch-power-script" -->
269273
```
270-
cd OpenROAD-flow-scripts/flow/results/sky130hd/ibex/base/
274+
cd OpenROAD-flow-scripts/flow/results/asap7/ibex/base/
271275
python3 peak_power.py --base base_output --total total_output --glitch glitch_output --csv power_analysis.csv
272276
```
273277

example/design/config.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
export DESIGN_NICKNAME = ibex
22
export DESIGN_NAME = ibex_core
3-
export PLATFORM = sky130hd
3+
export PLATFORM = asap7
44

55
export VERILOG_FILES = $(sort $(wildcard $(DESIGN_HOME)/src/$(DESIGN_NICKNAME)/*.v))
66
export SDC_FILE = $(DESIGN_HOME)/$(PLATFORM)/$(DESIGN_NICKNAME)/constraint.sdc

example/post_synthesis.vc

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,16 @@
55
--top-module ibex_simple_system
66
--exe
77
--timescale 1ns/10ps
8-
$CELL_SOURCES/formal_pdk.v
8+
$CELL_SOURCES/asap7sc7p5t_AO_RVT_TT_201020.v
9+
$CELL_SOURCES/asap7sc7p5t_AO_SRAM_TT_201020.v
10+
$CELL_SOURCES/asap7sc7p5t_INVBUF_RVT_TT_201020.v
11+
$CELL_SOURCES/asap7sc7p5t_INVBUF_SRAM_TT_201020.v
12+
$CELL_SOURCES/asap7sc7p5t_OA_RVT_TT_201020.v
13+
$CELL_SOURCES/asap7sc7p5t_OA_SRAM_TT_201020.v
14+
$CELL_SOURCES/asap7sc7p5t_SEQ_RVT_TT_220101.v
15+
$CELL_SOURCES/asap7sc7p5t_SEQ_SRAM_TT_220101.v
16+
$CELL_SOURCES/asap7sc7p5t_SIMPLE_RVT_TT_201020.v
17+
$CELL_SOURCES/asap7sc7p5t_SIMPLE_SRAM_TT_201020.v
918
common.vlt
1019
prim_assert.vlt
1120
prim_generic_clock_gating.vlt
@@ -120,7 +129,7 @@ prim_mubi28_dec.sv
120129
prim_mubi32_sender.sv
121130
prim_mubi32_sync.sv
122131
prim_mubi32_dec.sv
123-
verilog/ibex_core/ibex_core_synth_sky.v
132+
verilog/ibex_core/ibex_core_synth.v
124133
ram_1p.sv
125134
ram_2p.sv
126135
bus.sv

peak_power_example/peak_power.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,11 @@ def search_for_total_power(report_power: list[str]):
5858
os.makedirs(result_path)
5959

6060
tcl_script = """
61-
read_liberty $::env(LIB_DIR)/sky130_dummy_io.lib
62-
read_liberty $::env(LIB_DIR)/sky130_fd_sc_hd__tt_025C_1v80.lib
61+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_AO_RVT_FF_nldm_211120.lib.gz
62+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_INVBUF_RVT_FF_nldm_220122.lib.gz
63+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_OA_RVT_FF_nldm_211120.lib.gz
64+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SIMPLE_RVT_FF_nldm_211120.lib.gz
65+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SEQ_RVT_FF_nldm_220123.lib
6366
6467
read_db 5_route.odb
6568

saif_example/power.tcl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
1-
read_liberty $::env(LIB_DIR)/sky130_dummy_io.lib
2-
read_liberty $::env(LIB_DIR)/sky130_fd_sc_hd__tt_025C_1v80.lib
1+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_AO_RVT_FF_nldm_211120.lib.gz
2+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_INVBUF_RVT_FF_nldm_220122.lib.gz
3+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_OA_RVT_FF_nldm_211120.lib.gz
4+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SIMPLE_RVT_FF_nldm_211120.lib.gz
5+
read_liberty $::env(LIB_DIR)/asap7sc7p5t_SEQ_RVT_FF_nldm_220123.lib
36

47
read_db 5_route.odb
58

0 commit comments

Comments
 (0)