Skip to content

Commit 8b4264b

Browse files
committed
Merge remote-tracking branch 'origin/master' into secure-rsz-time-borrow-opt
# Conflicts: # src/rsz/test/cpp/CMakeLists.txt Signed-off-by: Jaehyun Kim <jhkim@precisioninno.com>
2 parents 2aa25ef + 58de265 commit 8b4264b

202 files changed

Lines changed: 21521 additions & 13852 deletions

File tree

Some content is hidden

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

.bazelrc

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,20 @@ build --cxxopt "-Wno-deprecated-copy-with-user-provided-copy" --host_cxxopt "-W
8383
build --per_file_copt=.*external/.*@-w
8484
build --host_per_file_copt=.*external/.*@-w
8585

86+
# Treat include paths into external/ (bzlmod/BCR deps) as -isystem so clang
87+
# suppresses ALL warnings from third-party headers pulled into our TUs (boost,
88+
# Eigen, googletest, ...), regardless of the specific warning. The
89+
# per_file_copt -w above only covers compiling external *source* files; this
90+
# covers external *headers* included by our own sources.
91+
#
92+
# The feature is global (target and exec config) and also demotes a from-source
93+
# dep's own -iquote entries to -isystem. Tools that rely on -iquote precedence
94+
# to shadow libc headers are patched to restore it -- e.g. git's
95+
# builtin/get-tar-commit-id.c includes git's own tar.h, which must win over
96+
# glibc's <tar.h>. See the git single_version_override in MODULE.bazel (same
97+
# class of fix as the bison/sed/gawk/m4 -I-over-isystem overrides).
98+
build --features=external_include_paths
99+
86100
# This avoid problems with building -c dbg which enables asserts.
87101
# Without this libstdc++ vs libc++ differences cause link errors.
88102
build --per_file_copt=.*external/abc.*@-stdlib=libc++
@@ -111,6 +125,9 @@ build:asan --copt=-DADDRESS_SANITIZER
111125
build:asan --copt=-O1
112126
build:asan --copt=-g
113127
build:asan --copt=-fno-omit-frame-pointer
128+
# Compress the DWARF debug sections (transparent to gdb/perf/addr2line).
129+
build:asan --copt=-gz=zlib
130+
build:asan --linkopt=-gz=zlib
114131
build:asan --linkopt=-fsanitize=address
115132
# TCMalloc is incompatible with ASan: __asan_init's interceptor setup calls
116133
# dlsym -> malloc before TCMalloc is initialized, segfaulting at startup.
@@ -123,6 +140,9 @@ build:profile --strip=never
123140
build:profile --copt -g --host_copt -g
124141
build:profile --copt -gmlt --host_copt -gmlt
125142
build:profile --copt -fno-omit-frame-pointer --host_copt -fno-omit-frame-pointer
143+
# Compress the DWARF debug sections (transparent to gdb/perf/addr2line).
144+
build:profile --copt=-gz=zlib --host_copt=-gz=zlib
145+
build:profile --linkopt=-gz=zlib
126146

127147
# Improve hermeticity by disallowing user envars and network access
128148
build --incompatible_strict_action_env

.bazelversion

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.6.0
1+
9.1.1

.github/workflows/buildifier.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434

3535
- name: Cache buildifier
3636
id: cache-buildifier
37-
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
37+
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
3838
with:
3939
path: ./buildifier
4040
key: ${{ runner.os }}-buildifier-${{ env.BUILDIFIER_VERSION }}

.github/workflows/github-actions-on-master-push.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
3030
- name: Cache buildifier
3131
id: cache-buildifier
32-
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
32+
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
3333
with:
3434
path: ./buildifier
3535
key: ${{ runner.os }}-buildifier-${{ env.BUILDIFIER_VERSION }}

.github/workflows/github-actions-update-grammar-railroad-diagrams.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ jobs:
2020
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2121

2222
- name: Set up Java
23-
uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4.8.0
23+
uses: actions/setup-java@0f481fcb613427c0f801b606911222b5b6f3083a # v5.5.0
2424
with:
2525
distribution: temurin
2626
java-version: "21"
2727

2828
- name: Cache railroad diagram tools
29-
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
29+
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
3030
id: cache-tools
3131
with:
3232
path: src/odb/doc/tools
@@ -82,7 +82,7 @@ jobs:
8282
8383
- name: Open PR if diagrams changed
8484
if: steps.diagram-changes.outputs.changed == 'true'
85-
uses: peter-evans/create-pull-request@22a9089034f40e5a961c8808d113e2c98fb63676 # v7.0.11
85+
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
8686
with:
8787
commit-message: "odb: regenerate LEF/DEF railroad diagram SVGs"
8888
branch: auto/grammar-railroad-diagrams

CMakeLists.txt

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,10 @@ set(CMAKE_CXX_EXTENSIONS OFF)
7575

7676
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
7777

78-
set_property(DIRECTORY PROPERTY TEST_DISCOVERY_TIMEOUT 60)
78+
# Defer GoogleTest case discovery from build time (POST_BUILD default, which
79+
# execs each test binary during the build) to ctest time. On a loaded CI host
80+
# the build-time discovery run can exceed the timeout and fail the whole build.
81+
set(CMAKE_GTEST_DISCOVER_TESTS_DISCOVERY_MODE PRE_TEST)
7982

8083
# Get version string in OPENROAD_VERSION
8184
if(NOT OPENROAD_VERSION)
@@ -180,6 +183,25 @@ if (LINK_TIME_OPTIMIZATION AND NOT LTO_UNSUPPORTED_OS)
180183
endif()
181184
message(STATUS "LTO/IPO is ${LTO_STATUS}")
182185

186+
# Compress DWARF debug sections in builds that emit debug info. This is a
187+
# large on-disk win for template-heavy C++ (debug info dominates these
188+
# binaries) and is transparent to gdb/readelf/addr2line/lldb. It is a no-op
189+
# for builds without -g (e.g. Release), so it is safe to apply globally.
190+
# Excluded on Apple platforms: Mach-O does not support -gz=zlib and AppleClang
191+
# (which CMAKE_CXX_COMPILER_ID matches as "Clang") would fail the build.
192+
# The compile flag is scoped to C/C++: -gz is a GCC/Clang host-compiler flag
193+
# that nvcc does not accept (it would need explicit -Xcompiler forwarding), so
194+
# applying it directory-wide would break CUDA (ENABLE_GPU) debug builds where
195+
# gpl marks GPU sources as LANGUAGE CUDA. The link flag needs no such guard:
196+
# linking is driven by the host C++ compiler.
197+
if((CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
198+
AND NOT APPLE)
199+
set(DEBUG_CONFIG_GENEX "$<OR:$<CONFIG:Debug>,$<CONFIG:RelWithDebInfo>>")
200+
add_compile_options(
201+
"$<$<AND:${DEBUG_CONFIG_GENEX},$<COMPILE_LANGUAGE:CXX,C>>:-gz=zlib>")
202+
add_link_options("$<${DEBUG_CONFIG_GENEX}:-gz=zlib>")
203+
endif()
204+
183205
# configure a header file to pass some of the CMake settings
184206
configure_file(
185207
${OPENROAD_HOME}/include/ord/Version.hh.cmake

MODULE.bazel

Lines changed: 57 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ bazel_dep(name = "platforms", version = "1.0.0")
2828
bazel_dep(name = "rules_bison", version = "0.3.1")
2929
bazel_dep(name = "rules_cc", version = "0.2.18")
3030
bazel_dep(name = "rules_flex", version = "0.3.1")
31+
32+
# rules_go is transitive (or-tools, gazelle, grpc-java, rules_buf). The
33+
# MVS-selected 0.53.0 references the top-level CcInfo global that Bazel 9
34+
# removed (go/private/rules/cgo.bzl), breaking analysis. 0.59.0+ loads
35+
# CcInfo from @rules_cc; force a Bazel-9-compatible release.
36+
bazel_dep(name = "rules_go", version = "0.61.1")
3137
bazel_dep(name = "rules_pkg", version = "1.2.0")
3238
bazel_dep(name = "rules_pycross", version = "0.8.1")
3339
bazel_dep(name = "rules_python", version = "1.8.5")
@@ -104,6 +110,14 @@ bazel_dep(name = "cudd", version = "3.0.0.bcr.2")
104110
bazel_dep(name = "eigen", version = "3.4.0.bcr.3")
105111
bazel_dep(name = "fmt", version = "11.2.0.bcr.1")
106112

113+
# freetype reaches the build transitively (qt-bazel -> harfbuzz -> freetype).
114+
# freetype@2.13.3's BUILD overlay calls the native cc_library rule, which
115+
# Bazel 9 removed, so loading the package fails. 2.13.3.bcr.2 keeps the same
116+
# 2.13.3 source but its overlay loads cc_library from @rules_cc. This is a
117+
# direct bazel_dep rather than a single_version_override so the pin propagates
118+
# to downstream consumers via MVS (overrides only apply in the root module).
119+
bazel_dep(name = "freetype", version = "2.13.3.bcr.2")
120+
107121
# gawk is transitive (abc -> ncurses -> gawk; yosys -> gawk). Same gnulib
108122
# libc-header shadowing as sed: gawk@5.3.2.bcr.2 fails to compile against
109123
# hermetic-llvm's explicit libc -isystem entries (BCR #7642). 5.3.2.bcr.7
@@ -114,6 +128,21 @@ single_version_override(
114128
)
115129

116130
bazel_dep(name = "git", version = "2.54.0")
131+
132+
# We enable the external_include_paths feature globally (see .bazelrc), which
133+
# demotes a repo's own -iquote entries to -isystem. git relies on -iquote
134+
# precedence for its quoted includes (builtin/get-tar-commit-id.c includes
135+
# git's own tar.h, which must shadow glibc's <tar.h>); the patch re-adds the
136+
# repo root as -iquote in GIT_COPTS so those includes keep precedence.
137+
single_version_override(
138+
module_name = "git",
139+
patch_strip = 1,
140+
patches = [
141+
"//bazel/git-patches:0001-iquote-own-headers-over-external_include_paths.patch",
142+
],
143+
version = "2.54.0",
144+
)
145+
117146
bazel_dep(name = "googletest", version = "1.17.0.bcr.2")
118147

119148
# m4 is transitive (rules_bison/rules_flex -> m4). Same gnulib libc-header
@@ -135,7 +164,10 @@ single_version_override(
135164
version = "4.9.bcr.5",
136165
)
137166

138-
bazel_dep(name = "spdlog", version = "1.15.1")
167+
# spdlog < 1.16.0.bcr.2's BUILD.bazel calls the native cc_test rule, which
168+
# Bazel 9 removed; loading the package fails. 1.16.0.bcr.2+ loads cc_test
169+
# from @rules_cc.
170+
bazel_dep(name = "spdlog", version = "1.17.0")
139171
bazel_dep(name = "sv-lang", version = "10.0.1-20260316-f04e8156")
140172
bazel_dep(name = "tcl_lang", version = "9.0.2.bcr.1")
141173

@@ -161,9 +193,16 @@ bazel_dep(name = "zlib", version = "1.3.1.bcr.8")
161193
# allow openroad to link, but will search on the system at runtime for
162194
# the correct system libs.
163195
bazel_dep(name = "qt-bazel")
196+
197+
# external_include_paths (see .bazelrc) moves Qt's external-repo include dirs
198+
# into compilation_context.external_includes. The moc rule at the older pin did
199+
# not gather those, so moc lost Qt's own header search paths and failed under
200+
# --config=lint (qtextimagehandler_p.h "Undefined interface", qfilesystemmodel.h
201+
# "Parse error at QT7_ONLY"). 541ebf6d teaches the moc rule to also collect
202+
# external_includes.
164203
git_override(
165204
module_name = "qt-bazel",
166-
commit = "886104974c2fd72439f2c33b5deebf0fe4649df7",
205+
commit = "541ebf6df76eef96c4de6343316b1c9d63e296f6",
167206
remote = "https://github.com/The-OpenROAD-Project/qt_bazel_prebuilts",
168207
)
169208

@@ -179,7 +218,7 @@ bazel_dep(name = "llvm", version = "0.8.11", dev_dependency = True)
179218
# --- Dev dependencies (not propagated to downstream consumers) ---
180219

181220
bazel_dep(name = "aspect_rules_lint", version = "2.5.2", dev_dependency = True)
182-
bazel_dep(name = "bant", version = "0.2.10", dev_dependency = True)
221+
bazel_dep(name = "bant", version = "0.3.0", dev_dependency = True)
183222
bazel_dep(name = "buildifier_prebuilt", version = "8.5.1.2", dev_dependency = True)
184223
bazel_dep(name = "rules_verilator", version = "0.1.0", dev_dependency = True)
185224
bazel_dep(name = "verilator", version = "5.036.bcr.3", dev_dependency = True)
@@ -192,7 +231,7 @@ bazel_dep(name = "rules_nodejs", version = "6.7.3", dev_dependency = True)
192231
bazel_dep(name = "bazel-orfs", dev_dependency = True)
193232
bazel_dep(name = "bazel-orfs-verilog", dev_dependency = True)
194233

195-
BAZEL_ORFS_COMMIT = "78f19f25cec73bdec3517a76465dec7ce17ce227"
234+
BAZEL_ORFS_COMMIT = "551d4c72749411c4b1168c0d12322a9c34817c91"
196235

197236
BAZEL_ORFS_REMOTE = "https://github.com/The-OpenROAD-Project/bazel-orfs.git"
198237

@@ -210,27 +249,30 @@ git_override(
210249
strip_prefix = "verilog",
211250
)
212251

213-
# bazel-orfs pulls in orfs without a version and patches yosys, relying on
214-
# overrides that only apply when bazel-orfs is the root module. Mirror them
215-
# here so OpenROAD-as-root can resolve the module graph.
252+
# @orfs marks most non-root-only directives (qt-bazel/yosys-slang git_overrides,
253+
# orfs.default(), toolchain registration) as dev_dependency, so they are no-ops
254+
# here. But @orfs//flow loads @bazel-orfs//:openroad.bzl, and @orfs marks its
255+
# bazel-orfs bazel_dep dev_dependency too, which drops @bazel-orfs from @orfs's
256+
# repo mapping when consumed non-root — so loading @orfs//flow fails. The patch
257+
# makes that one bazel_dep non-dev.
216258
#
217259
# Use archive_override (HTTPS tarball) rather than git_override so the
218260
# build resolves on networks that block direct git access to github.com.
219-
ORFS_COMMIT = "10a2baea2171059ec14cda9a5855aa26dd7572c6"
261+
ORFS_COMMIT = "4b3f2663609fd3f6fd8d862729de1ec5967eb4e6"
220262

221263
bazel_dep(name = "orfs", dev_dependency = True)
222264
archive_override(
223265
module_name = "orfs",
224266
patch_strip = 1,
225267
patches = [
226-
"//bazel/bazel-orfs-patches:0035-fix-remove-non-root-overrides-from-MODULE.bazel.patch",
268+
"//bazel/bazel-orfs-patches:0035-orfs-bazel-orfs-visible-non-root.patch",
227269
],
228-
sha256 = "8325c6755215857a87a84db078d47dfbb2dfcbef70eaf0dd376fe5a7a363cd58",
270+
sha256 = "b6e496221b5be5a5ecd54e978a7a8157a212b67374e2ecd6c27f90d35e02b473",
229271
strip_prefix = "OpenROAD-flow-scripts-" + ORFS_COMMIT,
230272
urls = ["https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/archive/" + ORFS_COMMIT + ".tar.gz"],
231273
)
232274

233-
bazel_dep(name = "yosys", version = "0.62.bcr.2", dev_dependency = True)
275+
bazel_dep(name = "yosys", version = "0.64", dev_dependency = True)
234276
bazel_dep(name = "yosys-slang", version = "0.0.0", dev_dependency = True)
235277
archive_override(
236278
module_name = "yosys-slang",
@@ -377,9 +419,12 @@ single_version_override(
377419

378420
# scip 9.2.3's tinycthread uses bare C11 <threads.h> names. Backport
379421
# scipopt/scip@cc917e07 (TNY_ prefix) until a fixed release lands in BCR.
422+
# The .bcr.1 revision keeps the 9.2.3 source (patch still applies) but its
423+
# overlay BUILD loads cc_library/cc_binary from @rules_cc rather than the
424+
# native rules Bazel 9 removed.
380425
single_version_override(
381426
module_name = "scip",
382427
patch_strip = 1,
383428
patches = ["//bazel:scip_tinycthread_tny_prefix.patch"],
384-
version = "9.2.3",
429+
version = "9.2.3.bcr.1",
385430
)

0 commit comments

Comments
 (0)