Repository navigation
perf(scheduler): avoid redundant change tracking - #3013
Merged
mergify[bot] merged 1 commit intoNov 2, 2026
Conversation
Acyclic process bodies run only at their first output projection, but settle planning charged every projection for the complete body and tracked all its reads and writes again. This generated partitions and change watches for work that is never executed, keeping large sets of old values live across the real body. Plan those reads, writes and costs only at the executing projection. Keep cyclic components and guarded regions unchanged. Remove the full flag-array population count at every settle: when individual flags are all set, their own guards already select every partition; an untracked raw view still forces a full settle. For larger event sets, evaluate stable clock edges in 64-bit value/mask batches. For SV sensitivity lists without occurrence counters, check four inputs at a time, stop at the first change, and refresh all baselines at initialization or a detected change. Preserve four-state X/Z transitions, ordinary event-control startup, and post-body rearming. Validation: 621 unit tests and 9,879 behavioral tests passed, with 20 existing skips. The common suite covers native/native-parallel, Cranelift/Cranelift-parallel and Wasm, with focused interpreter and differential scheduler coverage. Added coverage for 70 mixed edges crossing a word boundary and a long sensitivity list with early/late changes, repeated values and X/Z-only changes. The shared sensitivity case passes Icarus; Verilator's adapter reports its four-state expectations unsupported. Affected all-target Clippy, formatting and diff checks passed. E902/CoreMark four-state steady throughput now exceeds xezim in both long run orders on this machine. These are fresh measurements of this source tree on top of the merged #3003–#3005 stack, using one frozen binary. | Run order | Celox clocks/CPU-s | xezim clocks/CPU-s | CPU throughput gain | Wall throughput gain | | --- | ---: | ---: | ---: | ---: | | Celox first | 33148 | 30482 | 8.75% | 8.74% | | xezim first | 32605 | 30704 | 6.19% | 6.19% | Each engine completed 2,359,876 clocks with matching CoreMark CRCs. After warmup, alternate 34 matching 65,536-clock intervals (131,072..2,359,296); whole-window throughput uses process CPU time or wall time excluding controlled pauses. Both engines are pinned to logical CPU 8 on a Ryzen 7 9800X3D. No own builds or tests run during measurements; other machine load is uncontrolled. The Celox-first run had 12 MiB of huge-page-backed executable memory; the xezim-first run had ordinary pages and still won. RTLmeter revision `4fdd6c3fd154e9b99d3a9d713cf3f4977e284f94`, E902/CoreMark `+iterations=5 +max_cycles=1000000000`. Celox: `heliodor-dev` profile, native O2, four-state, one thread, `--unlimited --no-checkpoint-on-signal --report`. Comparison: xezim 0.11.4, binary SHA256 `afbe25c3906450a35335fb65da2ff6212f0b3e654a0f16c11a2f28a7c29d4e65`. Both use the same progress display once per 65,536 clocks in the existing negedge utility process, with no added RTL process and no two-state fallback. This qualifies post-JIT throughput for E902/CoreMark on this host. JIT-inclusive total time remains longer for Celox; these are instrumented measurements, not a claim about every RTLmeter design or unmodified release scores. Measured source tree: `39f916fbacbd5f76a9d476438b080cb755de5f2d`; Celox binary SHA256: `cf3cbb2eda57808751f79fd93f7387eacf1b97d7af9aebbe8c9bcbd189e03e82`. Full local interval records and CRC/input hashes: `work/change-tracking-final-{a,b}-{native,xezim}/results.json`. Source manifest, aggregate results and validation logs: `work/change-tracking-final-*`. Change-Id: Ia8c215051c2389f4ee7ffdd2af74466ee6d5ead1
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Contributor
✅ Merged into
|
37 of 64 tasks
mergify
Bot
deleted the
stack/tignear/perf/rtlmeter-change-tracking/avoid-redundant-change-tracking--a8c21505
branch
November 2, 2026 09:59
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Acyclic process bodies run only at their first output projection, but settle planning charged every projection for the complete body and tracked all its reads and writes again. This generated partitions and change watches for work that is never executed, keeping large sets of old values live across the real body.
Plan those reads, writes and costs only at the executing projection. Keep cyclic components and guarded regions unchanged. Remove the full flag-array population count at every settle: when individual flags are all set, their own guards already select every partition; an untracked raw view still forces a full settle.
For larger event sets, evaluate stable clock edges in 64-bit value/mask batches. For SV sensitivity lists without occurrence counters, check four inputs at a time, stop at the first change, and refresh all baselines at initialization or a detected change. Preserve four-state X/Z transitions, ordinary event-control startup, and post-body rearming.
Validation: 621 unit tests and 9,879 behavioral tests passed, with 20 existing skips. The common suite covers native/native-parallel, Cranelift/Cranelift-parallel and Wasm, with focused interpreter and differential scheduler coverage. Added coverage for 70 mixed edges crossing a word boundary and a long sensitivity list with early/late changes, repeated values and X/Z-only changes. The shared sensitivity case passes Icarus; Verilator's adapter reports its four-state expectations unsupported. Affected all-target Clippy, formatting and diff checks passed.
E902/CoreMark four-state steady throughput now exceeds xezim in both long run orders on this machine. These are fresh measurements of this source tree on top of the merged #3003–#3005 stack, using one frozen binary.
Each engine completed 2,359,876 clocks with matching CoreMark CRCs. After warmup, alternate 34 matching 65,536-clock intervals (131,072..2,359,296); whole-window throughput uses process CPU time or wall time excluding controlled pauses. Both engines are pinned to logical CPU 8 on a Ryzen 7 9800X3D. No own builds or tests run during measurements; other machine load is uncontrolled. The Celox-first run had 12 MiB of huge-page-backed executable memory; the xezim-first run had ordinary pages and still won.
RTLmeter revision
4fdd6c3fd154e9b99d3a9d713cf3f4977e284f94, E902/CoreMark+iterations=5 +max_cycles=1000000000. Celox:heliodor-devprofile, native O2, four-state, one thread,--unlimited --no-checkpoint-on-signal --report. Comparison: xezim 0.11.4, binary SHA256afbe25c3906450a35335fb65da2ff6212f0b3e654a0f16c11a2f28a7c29d4e65. Both use the same progress display once per 65,536 clocks in the existing negedge utility process, with no added RTL process and no two-state fallback.This qualifies post-JIT throughput for E902/CoreMark on this host. JIT-inclusive total time remains longer for Celox; these are instrumented measurements, not a claim about every RTLmeter design or unmodified release scores.
Measured source tree:
39f916fbacbd5f76a9d476438b080cb755de5f2d; Celox binary SHA256:cf3cbb2eda57808751f79fd93f7387eacf1b97d7af9aebbe8c9bcbd189e03e82. Full local interval records and CRC/input hashes:work/change-tracking-final-{a,b}-{native,xezim}/results.json. Source manifest, aggregate results and validation logs:work/change-tracking-final-*.