Skip to content

build: install OpenROAD with Bazel - #4527

Merged
maliberty merged 6 commits into
The-OpenROAD-Project:masterfrom
vvbandeira:openroad-bazel
Sep 17, 2026
Merged

maliberty merged 6 commits into
The-OpenROAD-Project:masterfrom
vvbandeira:openroad-bazel

Conversation

@vvbandeira

Copy link
Copy Markdown
Member

OpenROAD Build.sh owns both compilation and installation. Remove the CMake-only argument path and use its Bazel install prefix in the ORFS images.

OpenROAD Build.sh owns both compilation and installation. Remove the CMake-only argument path and use its Bazel install prefix in the ORFS images.

Signed-off-by: Vitor Bandeira <vvbandeira@precisioninno.com>

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the OpenROAD build script to use Bash arrays for managing build arguments, simplifying the build process by delegating directly to Build.sh. It also removes the openroadVersion build argument from the Docker builder files and updates the Dockerfile to copy the binary from the install directory. Feedback was provided on build_openroad.sh regarding the parsing of --openroad-args, suggesting the use of eval to prevent issues with backslash stripping and quote handling associated with the current xargs implementation.

Comment thread build_openroad.sh Resolved
The builder stage ran the OpenROAD installer with -bazel before
build_openroad.sh. That step runs apt-get update inside the builder
image. On the CI Docker hosts, apt could not create its temporary file
under /tmp, and the image build failed.

The dev image already runs apt to install every other base dependency.
Bazel is now part of -base and -all in the ORFS installer, so bazelisk
and its runtime libraries land in the dev image. The dev image tag
changes with the installer, so CI rebuilds it.

Signed-off-by: Vitor Bandeira <vvbandeira@precisioninno.com>
@openroad-ci

openroad-ci commented Sep 10, 2026 •

Copy link
Copy Markdown
Member

🔍 QoR check

Metrics reflect the PR merge build — i.e. what will land on the target branch.

Commit 685ccf0 · Jenkins build #10 · Baseline: build · View build on dashboard

62 design(s) checked — 8 with regression(s), 0 without a comparable baseline.

❌ asap7/riscv32i base — 2 failing metric(s)
Metric target base delta limit band
finish__timing__setup__tns -11114.4 -5348.68 107.79706394848823% -6418.416 PeriodPadding 20%
globalroute__timing__setup__tns -7597.8 -3367.1 125.64818389712215% -4040.52 PeriodPadding 20%
❌ ihp-sg13g2/riscv32i base — 2 failing metric(s)
Metric target base delta limit band
finish__timing__setup__ws -2.46482 -2.23513 10.276359764309012% -2.3468865 PeriodPadding 5.0%
globalroute__timing__setup__ws -2.58651 -2.45241 5.4680905721310875% -2.5750305 PeriodPadding 5.0%
❌ nangate45/mempool_group base — 1 failing metric(s)
Metric target base delta limit band
finish__timing__hold__tns -1.81203 -0.199461 808.4633086167221% -0.799461 PeriodPadding 20%
❌ sky130hd/aes base — 1 failing metric(s)
Metric target base delta limit band
globalroute__timing__setup__tns -2.73004 -1.41136 93.43328420813967% -2.13136 PeriodPadding 20%
❌ sky130hd/chameleon base — 1 failing metric(s)
Metric target base delta limit band
finish__timing__setup__tns -3.04633 -2.07471 46.831605380993004% -2.67471 PeriodPadding 20%
❌ sky130hd/microwatt base — 1 failing metric(s)
Metric target base delta limit band
globalroute__antenna_diodes_count 3765 3095 21.647819063004846% 3098.095 Metric 0.1%
❌ sky130hd/riscv32i base — 3 failing metric(s)
Metric target base delta limit band
cts__timing__setup__tns -100.304 -58.2255 72.26816429227743% -69.8706 PeriodPadding 20%
finish__timing__setup__tns -64.4089 -32.6139 97.48910740512481% -39.13668 PeriodPadding 20%
globalroute__timing__setup__tns -186.812 -93.1894 100.46485973726625% -111.82728 PeriodPadding 20%
❌ sky130hs/ibex base — 1 failing metric(s)
Metric target base delta limit band
cts__timing__setup__tns -258.39 -64.0475 303.4349506225848% -76.857 PeriodPadding 20%

vvbandeira and others added 4 commits September 10, 2026 11:43
Signed-off-by: Vitor Bandeira <vvbandeira@precisioninno.com>
The Bazel build defaults to -O2 without LTO. The CMake RELEASE build
used -O3 with LTO. The two binaries give different QoR from CTS
onward, and CI compared the Bazel binary against a CMake baseline.
Pass -lto so Build.sh uses --config=opt and the binary is closer to
the previous one.

Signed-off-by: Vitor Bandeira <vvbandeira@precisioninno.com>
The parser used xargs, which removes backslashes. A path such as
C:\projects became C:projects. A pure-bash tokenizer now splits the
string. Quotes still group one argument that holds spaces. Every other
character stays literal, and nothing is expanded.

Signed-off-by: Vitor Bandeira <vvbandeira@precisioninno.com>
Signed-off-by: Matt Liberty <mliberty@precisioninno.com>
@maliberty maliberty added the UpdateRules Starts GHA to update rules label Sep 13, 2026
@maliberty
maliberty merged commit 3000fc7 into The-OpenROAD-Project:master Sep 17, 2026
10 of 12 checks passed
@vvbandeira
vvbandeira deleted the openroad-bazel branch September 25, 2026 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

UpdateRules Starts GHA to update rules

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants