Skip to content

Put the CPU model in the bench cache's shared-key - #57

Merged
lpgauth merged 1 commit into
mainfrom
fix/bench-pgo-cache-cpu-key
Sep 14, 2026
Merged

lpgauth merged 1 commit into
mainfrom
fix/bench-pgo-cache-cpu-key

Conversation

@lpgauth

@lpgauth lpgauth commented Sep 14, 2026

Copy link
Copy Markdown
Owner

Swatinem/rust-cache treats shared-key and key as mutually exclusive: key is appended only when shared-key is unset (config.ts:73-88).

So the CPU model added in #54 was computed and then discarded. In run 34847555030:

key: AMD-EPYC-7763-64-Core-Processor
Restored from cache key "v1-bench-x86_64-unknown-linux-gnu-Linux-x64-6ff13d87-3f21e574" full match: true

The job landed on an EPYC 7763 (Zen 3, no AVX-512) and restored libthiserror_impl-*.so built under -C target-cpu=native on an AVX-512 Intel runner, so rustc took SIGILL expanding the derive for sonic-rs.

Fold the model into shared-key and drop key. The new prefix also means the poisoned entry can't be restored, so no manual cache purge is needed.

release.yml is unaffected: its matrix pins explicit -C target-cpu=x86-64{,-v2,-v3}, never native.

rust-cache appends its `key` input only when `shared-key` is unset, so
the CPU model added in #54 never reached the cache key: the benchmark job
kept restoring `v1-bench-x86_64-unknown-linux-gnu-Linux-x64-...`. A run
on an AMD EPYC 7763 restored proc-macro .so files built on an AVX-512
Intel runner and rustc took SIGILL expanding thiserror's derive.

Fold the model into shared-key and drop the key input.
@lpgauth
lpgauth merged commit 7df0f8f into main Sep 14, 2026
4 checks passed
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