Skip to content

test: cache the test-support query with the rule graph - #15315

Merged
TrapsterDK merged 1 commit into
mainfrom
speed-test-support-query-cache
Nov 30, 2026
Merged

TrapsterDK merged 1 commit into
mainfrom
speed-test-support-query-cache

Conversation

@TrapsterDK

Copy link
Copy Markdown
Collaborator

Part of #15298.

A warm dx test with no BUILD/.bzl change now makes one Bazel launcher call instead of two. The test-support query result is stored in GraphCache (new test_support state file, added to CLEAN_ENTRIES) with the same key as the rule graph (graph inputs and file list), plus the selection argv and the query expression, so a different scope never reuses it. Failed queries are not cached; output is unchanged.

Benchmark: fresh dx init Rust consumer, warm dx test, binaries built from origin/main and this branch, interleaved runs, wall ms.

  • 5 runs: median before 614, after 552.
  • 15 runs: median before 700, after 439 (before 526-967, after 380-745).

Tests: tools/dx test //cli/plan:dx_plan_test //cli/path:dx_path_test -- --jobs=4 passes (2 of 2). The check with --apply on both packages made no changes.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Xut2hxb7tMzRqzVaKmAvVT

@TrapsterDK
TrapsterDK merged commit d296d63 into main Nov 30, 2026
7 of 8 checks passed
@TrapsterDK
TrapsterDK deleted the speed-test-support-query-cache branch November 30, 2026 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant