Skip to content

Commit 13d1d4b

Browse files
committed
Merge branch 'master' into secure-pin_access
Signed-off-by: Eder Monteiro <[email protected]>
2 parents c8f7ee2 + 58a7f80 commit 13d1d4b

File tree

167 files changed

+2531
-53779
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

167 files changed

+2531
-53779
lines changed

dev_env.sh

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
11
#!/usr/bin/env bash
2-
3-
function setpaths() {
2+
#
3+
# Set developer paths and environment variables here,
4+
# user settings go in ./env.sh
5+
function __setpaths() {
46
local DIR=$(readlink -f "$(dirname "${BASH_SOURCE[0]}")")
7+
[ "$(find $DIR/dependencies -type f -user root)" ] && echo "WARNING! Files set up by sudo found in $DIR"
58
export PATH="$DIR/dependencies/bin:$PATH"
69
export CMAKE_INSTALL_RPATH=$DIR/dependencies/lib:$DIR/dependencies/lib64
7-
}
810

9-
setpaths
11+
if [[ "$OSTYPE" == "darwin"* ]]; then
12+
export CMAKE_PREFIX_PATH="$(brew --prefix or-tools)"
13+
fi
14+
}
15+
__setpaths
16+
unset -f __setpaths

docker/Dockerfile.dev

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,12 @@ COPY InstallerOpenROAD.sh \
1515
ARG options=""
1616
ARG constantBuildDir="-constant-build-dir"
1717

18-
RUN env CFLAGS="-D__TIME__=0 -D__DATE__=0 -D__TIMESTAMP__=0 -Wno-builtin-macro-redefined" \
19-
CXXFLAGS="-D__TIME__=0 -D__DATE__=0 -D__TIMESTAMP__=0 -Wno-builtin-macro-redefined" \
20-
./DependencyInstaller.sh $options $constantBuildDir \
21-
&& rm -rf /tmp/installer /tmp/* /var/tmp/* /var/lib/apt/lists/*
18+
ENV CFLAGS="-D__TIME__=0 -D__DATE__=0 -D__TIMESTAMP__=0 -Wno-builtin-macro-redefined"
19+
ENV CXXFLAGS="-D__TIME__=0 -D__DATE__=0 -D__TIMESTAMP__=0 -Wno-builtin-macro-redefined"
20+
21+
RUN ./DependencyInstaller.sh -base $options $constantBuildDir \
22+
&& ./DependencyInstaller.sh -common $options $constantBuildDir \
23+
&& rm -rf /tmp/installer /tmp/* /var/tmp/* /var/lib/apt/lists/*
2224

2325
ARG fromImage
2426

docs/user/BuildLocally.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44

55
The `setup.sh` script installs all of the dependencies, including OpenROAD dependencies, if they are not already installed.
66

7-
Supported configurations are: CentOS 7, Ubuntu 20.04, Ubuntu 22.04, Ubuntu 22.04(aarch64), RHEL 8,
8-
Debian 10 and Debian 11.
7+
Supported configurations are: Ubuntu 20.04, Ubuntu 22.04, Ubuntu 22.04(aarch64), RHEL 8, RockyLinux 9 and Debian 11.
98

109
``` shell
1110
git clone --recursive https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts

docs/user/BuildWithPrebuilt.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
# Using Pre-built Binaries
22

33
## Install Klayout and Yosys
4-
Please ensure the Klayout version (denoted with `klayoutVersion` variable) is consistent with the one used in [DependencyInstaller script](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/etc/DependencyInstaller.sh).
4+
Please ensure the Klayout version (denoted with `klayoutVersion` variable) is consistent with the one used in [DependencyInstaller script](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/etc/DependencyInstaller.sh).
55

66
Instructions for installing:
77
- [Klayout>=0.28.8](https://www.klayout.de/build.html)
88
- [Yosys>=0.39](https://github.com/YosysHQ/oss-cad-suite-build/blob/master/README.md#installation)
99

10-
```{tip} Unfortunately KLayout maintainers do not provide Debian 10/11 compatible packages. You can follow the build-from-sources instruction (Version >=0.25) and Ubuntu 22 instructions [here](https://www.klayout.de/build.html#:~:text=Building%20KLayout%20on%20Linux%20(Version%20%3E%3D%200.25)).
10+
```{tip} Unfortunately KLayout maintainers do not provide Debian 11 compatible packages. You can follow the build-from-sources instruction (Version >=0.25) and Ubuntu 22 instructions [here](https://www.klayout.de/build.html#:~:text=Building%20KLayout%20on%20Linux%20(Version%20%3E%3D%200.25)).
1111
```
1212

1313
## Install OpenROAD
@@ -19,7 +19,7 @@ Thanks to [Precision Innovations](https://precisioninno.com/) for hosting and ma
1919

2020
The following platforms are supported currently:
2121
- Ubuntu 20.04/22.04
22-
- Debian 10/11
22+
- Debian 11
2323

2424
Use the following steps to download:
2525

@@ -29,24 +29,24 @@ Step 2: Download the artifacts for your distribution.
2929

3030
Step 3: Run the install command based on platform use package installer.
3131
For example Ubuntu 20.04 use:
32-
32+
3333
```shell
3434
sudo apt install ./openroad_2.0_amd64-ubuntu20.04.deb
3535
```
3636

3737
## Install Klayout and Yosys
38-
Please ensure the Klayout version (denoted with `klayoutVersion` variable) is consistent with the one used in [DependencyInstaller script](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/etc/DependencyInstaller.sh).
38+
Please ensure the Klayout version (denoted with `klayoutVersion` variable) is consistent with the one used in [DependencyInstaller script](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/blob/master/etc/DependencyInstaller.sh).
3939

4040
Instructions for installing:
4141
- [Klayout>=0.28.8](https://www.klayout.de/build.html)
4242
- [Yosys>=0.39](https://github.com/YosysHQ/oss-cad-suite-build/blob/master/README.md#installation)
4343

44-
```{tip} Unfortunately KLayout maintainers do not provide Debian 10/11 compatible packages. You can follow the build-from-sources instruction (Version >=0.25) and Ubuntu 22 instructions [here](https://www.klayout.de/build.html#:~:text=Building%20KLayout%20on%20Linux%20(Version%20%3E%3D%200.25)).
44+
```{tip} Unfortunately KLayout maintainers do not provide Debian 11 compatible packages. You can follow the build-from-sources instruction (Version >=0.25) and Ubuntu 22 instructions [here](https://www.klayout.de/build.html#:~:text=Building%20KLayout%20on%20Linux%20(Version%20%3E%3D%200.25)).
4545
```
4646

4747

4848
## Verify Installation
49-
You may clone the OpenROAD-flow-scripts repository non-recursively.
49+
You may clone the OpenROAD-flow-scripts repository non-recursively.
5050

5151
```
5252
git clone https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts.git
@@ -60,7 +60,7 @@ export OPENROAD_EXE=$(command -v openroad)
6060
export YOSYS_EXE=$(command -v yosys)
6161
6262
# only if KLayout is built from source
63-
export LD_LIBRARY_PATH="<klayout_location>/bin:$PATH"
63+
export LD_LIBRARY_PATH="<klayout_location>/bin:$PATH"
6464
6565
yosys -help
6666
openroad -help

docs/user/BuildWithWSL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Windows Subsystem for Linux, or WSL for short is a way for you to mount a Linux-based OS onto your Windows machine, allowing you to build OpenROAD-flow-scripts both locally and via Docker.
33

44
## Install WSL
5-
Instructions to install WSL can be found [here](https://learn.microsoft.com/en-us/windows/wsl/install). You may use any kernel supported, such as: CentOS 7, Ubuntu 20.04, Ubuntu 22.04, RHEL 8, Debian 10 and Debian 11.
5+
Instructions to install WSL can be found [here](https://learn.microsoft.com/en-us/windows/wsl/install). You may use any kernel supported, such as: Ubuntu 20.04, Ubuntu 22.04, RHEL 8, RockyLinux 9, Debian 11.
66

77
We recommend that users follow the Docker build by continuing onto the guide below. However, if you wish to install locally, you may follow the build locally instructions [here](./BuildLocally.md).
88

docs/user/DockerShell.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,10 @@ If you need to use a different Docker image than default, override by using the
3333
environment variable:
3434

3535
```
36-
OR_IMAGE=openroad/flow-centos7-builder:v1234 util/docker_shell make
36+
OR_IMAGE=openroad/flow-ubuntu22.04-builder:v1234 util/docker_shell make
3737
```
3838

39-
If you have built your OpenROAD Docker image using prebuilt binaries,
39+
If you have built your OpenROAD Docker image using prebuilt binaries,
4040
you might want to source custom paths for your modules as follows.
4141

4242
```

docs/user/FlowVariables.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ configuration file.
181181
| <a name="SYNTH_ARGS"></a>SYNTH_ARGS| Optional synthesis variables for yosys.| -flatten| |
182182
| <a name="SYNTH_GUT"></a>SYNTH_GUT| Load design and remove all internal logic before doing synthesis. This is useful when creating a mock .lef abstract that has a smaller area than the amount of logic would allow. bazel-orfs uses this to mock SRAMs, for instance.| | |
183183
| <a name="SYNTH_HIERARCHICAL"></a>SYNTH_HIERARCHICAL| Enable to Synthesis hierarchically, otherwise considered flat synthesis.| 0| |
184+
| <a name="SYNTH_MEMORY_MAX_BITS"></a>SYNTH_MEMORY_MAX_BITS| Maximum number of bits for memory synthesis.| 4096| |
184185
| <a name="TAPCELL_TCL"></a>TAPCELL_TCL| Path to Endcap and Welltie cells file.| | |
185186
| <a name="TAP_CELL_NAME"></a>TAP_CELL_NAME| Name of the cell to use in tap cell insertion.| | |
186187
| <a name="TECH_LEF"></a>TECH_LEF| A technology LEF file of the PDK that includes all relevant information regarding metal layers, vias, and spacing requirements.| | |
@@ -209,6 +210,7 @@ configuration file.
209210
- [SDC_GUT](#SDC_GUT)
210211
- [SYNTH_GUT](#SYNTH_GUT)
211212
- [SYNTH_HIERARCHICAL](#SYNTH_HIERARCHICAL)
213+
- [SYNTH_MEMORY_MAX_BITS](#SYNTH_MEMORY_MAX_BITS)
212214
- [TIEHI_CELL_AND_PORT](#TIEHI_CELL_AND_PORT)
213215
- [TIELO_CELL_AND_PORT](#TIELO_CELL_AND_PORT)
214216
- [VERILOG_FILES](#VERILOG_FILES)

docs/user/InstructionsForAutoTuner.md

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,27 +124,40 @@ The following commands should be run from `./tools/AutoTuner`.
124124

125125
#### Tune only
126126

127-
* AutoTuner: `python3 -m autotuner.distributed tune -h`
127+
* AutoTuner: `openroad_autotuner tune -h`
128128

129129
Example:
130130

131131
```shell
132-
python3 -m autotuner.distributed --design gcd --platform sky130hd \
132+
openroad_autotuner --design gcd --platform sky130hd \
133133
--config ../../flow/designs/sky130hd/gcd/autotuner.json \
134134
tune --samples 5
135135
```
136136
#### Sweep only
137137

138-
* Parameter sweeping: `python3 -m autotuner.distributed sweep -h`
138+
* Parameter sweeping: `openroad_autotuner sweep -h`
139139

140140
Example:
141141

142142
```shell
143-
python3 -m autotuner.distributed --design gcd --platform sky130hd \
143+
openroad_autotuner --design gcd --platform sky130hd \
144144
--config src/autotuner/distributed-sweep-example.json \
145145
sweep
146146
```
147147

148+
#### Plot images
149+
150+
After running an AutoTuner experiment, you can generate a graph to understand the results better.
151+
The graph will show the progression of one metric (see list below) over the execution of the experiment.
152+
153+
- QoR
154+
- Runtime per trial
155+
- Clock Period
156+
- Worst slack
157+
158+
```shell
159+
python3 utils/plot.py --results_dir <your-autotuner-result-path>
160+
```
148161

149162
### Google Cloud Platform (GCP) distribution with Ray
150163

env.sh

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,25 @@
1-
if [[ "$OSTYPE" == "darwin"* ]]; then
2-
DIR="$(dirname $(perl -e 'use Cwd "abs_path";print abs_path(shift)' "${BASH_SOURCE[0]}"))"
3-
else
4-
DIR="$(dirname $(readlink -f "${BASH_SOURCE[0]}"))"
5-
fi
1+
#!/usr/bin/env bash
2+
function __setpaths() {
3+
if [[ "$OSTYPE" == "darwin"* ]]; then
4+
DIR="$(dirname $(perl -e 'use Cwd "abs_path";print abs_path(shift)' "${BASH_SOURCE[0]}"))"
5+
else
6+
DIR="$(dirname $(readlink -f "${BASH_SOURCE[0]}"))"
7+
fi
68

7-
if [ -f /opt/rh/rh-python38/enable ]; then
8-
source /opt/rh/rh-python38/enable
9-
fi
9+
export OPENROAD=${DIR}/tools/OpenROAD
10+
echo "OPENROAD: ${OPENROAD}"
1011

11-
export OPENROAD=${DIR}/tools/OpenROAD
12-
echo "OPENROAD: ${OPENROAD}"
12+
# Set user paths and environment variables here,
13+
# developer settings go in ./dev_env.sh
14+
export PATH=${DIR}/tools/install/OpenROAD/bin:$PATH
15+
export PATH=${DIR}/tools/install/yosys/bin:$PATH
1316

14-
export PATH=${DIR}/dependencies/bin:$PATH
15-
export PATH=${DIR}/tools/install/OpenROAD/bin:$PATH
16-
export PATH=${DIR}/tools/install/yosys/bin:$PATH
17+
if [[ "$OSTYPE" == "darwin"* ]]; then
18+
export PATH="/Applications/KLayout/klayout.app/Contents/MacOS:$PATH"
19+
export PATH="$(brew --prefix bison)/bin:$(brew --prefix flex)/bin:$(brew --prefix tcl-tk)/bin:$PATH"
20+
fi
1721

18-
if [[ "$OSTYPE" == "darwin"* ]]; then
19-
export PATH="/Applications/KLayout/klayout.app/Contents/MacOS:$PATH"
20-
export PATH="$(brew --prefix bison)/bin:$(brew --prefix flex)/bin:$(brew --prefix tcl-tk)/bin:$PATH"
21-
export CMAKE_PREFIX_PATH="$(brew --prefix or-tools)"
22-
fi
23-
24-
export FLOW_HOME=$DIR/flow
22+
export FLOW_HOME=$DIR/flow
23+
}
24+
__setpaths
25+
unset -f __setpaths

etc/DependencyInstaller.sh

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ OR_INSTALLER_ARGS="-eqy"
260260
# default prefix
261261
PREFIX=""
262262
# default option
263-
option="all"
263+
option="none"
264264
# default isLocal
265265
isLocal="false"
266266
constantBuildDir="false"
@@ -272,16 +272,20 @@ while [ "$#" -gt 0 ]; do
272272
-h|-help)
273273
_help 0
274274
;;
275+
-all)
276+
if [[ "${option}" != "none" ]]; then
277+
echo "WARNING: previous argument -${option} will be overwritten with -all." >&2
278+
fi
279+
option="all"
280+
;;
275281
-base)
276-
OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -base"
277-
if [[ "${option}" != "all" ]]; then
282+
if [[ "${option}" != "none" ]]; then
278283
echo "WARNING: previous argument -${option} will be overwritten with -base." >&2
279284
fi
280285
option="base"
281286
;;
282287
-common)
283-
OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -common"
284-
if [[ "${option}" != "all" ]]; then
288+
if [[ "${option}" != "none" ]]; then
285289
echo "WARNING: previous argument -${option} will be overwritten with -common." >&2
286290
fi
287291
option="common"
@@ -309,6 +313,13 @@ while [ "$#" -gt 0 ]; do
309313
shift 1
310314
done
311315

316+
if [[ "${option}" == "none" ]]; then
317+
echo "You must use one of: -all|-base|-common" >&2
318+
_help
319+
fi
320+
321+
OR_INSTALLER_ARGS="${OR_INSTALLER_ARGS} -${option}"
322+
312323
platform="$(uname -s)"
313324
case "${platform}" in
314325
"Linux" )

0 commit comments

Comments
 (0)