Skip to content

bazel: run CopyToDirectory locally in CI instead of via the cache - #12092

Merged
maliberty merged 2 commits into
The-OpenROAD-Project:masterfrom
The-OpenROAD-Project-staging:ci-copytodirectory-no-cache
Nov 1, 2026
Merged

maliberty merged 2 commits into
The-OpenROAD-Project:masterfrom
The-OpenROAD-Project-staging:ci-copytodirectory-no-cache

Conversation

@maliberty

Copy link
Copy Markdown
Member

The hermetic LLVM toolchain stages the libc++ headers (~1,700 files, 16 MB) into one include directory with a bazel_lib CopyToDirectory action (@llvm-project//libcxx:libcxx_headers_include_search_directory, in both target and exec configs). Every C++ compile in that configuration takes the directory as an input, so nothing downstream can even start a cache lookup until the copy finishes.

In CI (e.g. PR-12091-merge #1) this action sat in the disk-cache stage for 160–380 s on cold or busy nodes while every compile waited ((16 actions, 0 running)). A cache hit on a tree artifact checks every file; running the copy locally takes well under a second.

This adds build:ci --modify_execution_info=CopyToDirectory=+no-cache, so all CopyToDirectory actions in CI run locally and skip both caches. They are all cheap file copies.

The hermetic toolchain stages libc++ headers (~1,700 files) with a
CopyToDirectory action that every C++ compile depends on. A cache hit
for that tree artifact checks every file, and on a cold or busy disk
cache it took 160-380 s in CI while all compiles waited. Running the
copy locally takes well under a second.

Signed-off-by: Matt Liberty <mliberty@precisioninno.com>
@maliberty maliberty self-assigned this Nov 1, 2026

@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 updates the .bazelrc configuration file to modify the execution info for CI builds. Specifically, it adds build:ci --modify_execution_info=CopyToDirectory=+no-cache to ensure that CopyToDirectory staging runs locally instead of using the disk cache, preventing potential delays on cold or busy disk caches. There are no review comments, and I have no additional feedback to provide.

The Docker and release builds use --config=release, so the CI-only
setting did not reach them, and they stalled up to 435 s on the libc++
header tree copy.

Signed-off-by: Matt Liberty <mliberty@precisioninno.com>
@maliberty
maliberty marked this pull request as ready for review November 1, 2026 04:15
@maliberty
maliberty requested review from a team as code owners November 1, 2026 04:15
@maliberty
maliberty merged commit 40ab0df into The-OpenROAD-Project:master Nov 1, 2026
20 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-11-01T04:15:21.898390Z
We couldn’t complete this review. Comment @codex review to try again.
c7fa39f Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@maliberty
maliberty deleted the ci-copytodirectory-no-cache branch November 1, 2026 04:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant