Skip to content

Commit 61e3af2

Browse files
oharboejbylicki
authored andcommitted
bazel: test bazel configuration on a few designs
Signed-off-by: Øyvind Harboe <[email protected]>
1 parent 7888641 commit 61e3af2

File tree

6 files changed

+205
-0
lines changed

6 files changed

+205
-0
lines changed

flow/.bazelrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
build --incompatible_strict_action_env
2+
try-import %workspace%/.user-bazelrc

flow/.bazelversion

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
7.2.1

flow/BUILD.bazel

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
load("@bazel-orfs//:openroad.bzl", "orfs_flow")
2+
3+
filegroup(
4+
name = "constraints-sdc",
5+
srcs = [
6+
"designs/asap7/gcd/constraint.sdc",
7+
],
8+
visibility = [":__subpackages__"],
9+
)
10+
11+
orfs_flow(
12+
name = "gcd",
13+
stage_args = {
14+
"synth": {
15+
"SDC_FILE": "$(location :constraints-sdc)",
16+
},
17+
"floorplan": {
18+
"DIE_AREA": "0 0 16.2 16.2",
19+
"CORE_AREA": "1.08 1.08 15.12 15.12",
20+
},
21+
"place": {
22+
"PLACE_DENSITY": "0.35",
23+
},
24+
},
25+
stage_sources = {
26+
"synth": [":constraints-sdc"],
27+
},
28+
verilog_files = glob(include=["designs/src/gcd/*.v"]),
29+
)

flow/MODULE.bazel

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
module(
2+
name = "orfs",
3+
version = "0.0.1",
4+
compatibility_level = 1,
5+
)
6+
7+
bazel_dep(name = "bazel-orfs")
8+
git_override(
9+
module_name = "bazel-orfs",
10+
commit = "16eb5dd5b31bdeacc0b3006a71dbce29076e9850",
11+
remote = "https://github.com/The-OpenROAD-Project/bazel-orfs.git",
12+
)
13+
14+
# Read: https://github.com/The-OpenROAD-Project/bazel-orfs?tab=readme-ov-file#usage
15+
#
16+
# TL;DR
17+
#
18+
# 1. uncomment below
19+
# 2. comment git_override() above
20+
#
21+
#local_path_override(
22+
# module_name = "bazel-orfs", path = "../bazel-orfs"
23+
#)
24+
25+
orfs = use_extension("@bazel-orfs//:extension.bzl", "orfs_repositories")
26+
orfs.default(
27+
image = "openroad/orfs:v3.0-1114-g46acc762",
28+
sha256 = "ae4df23391c26bcc48a506f8e0d0da73742d1b6cb3b1dc02f4d5ea71170195b5",
29+
)

flow/MODULE.bazel.lock

Lines changed: 142 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flow/WORKSPACE.bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# This file marks the root of the Bazel workspace.
2+
# See MODULE.bazel for external dependencies setup.

0 commit comments

Comments
 (0)