Repository navigation
Conversation
…d guard custom rule CPU Native session analyses built a new InferredColumn per model column, while Python's compact analysis shares one object per distinct column. Custom-rule hosts therefore pickled and decoded more distinct objects under native-preview. Adds custom_rules_cpu_ms (rule thread plus host children CPU) and a same-runner ratio entry for it.
Contributor
Author
|
Landed together in #1075 to cut merge-queue CI runs; review history stays here. |
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.
Why
Custom rules ran 1.2-1.3x slower (wall) under
native-previewthan python on the dense 3,000-model project. In CPU the gap was real: 1.151x (1794 vs 1559 ms, 5 alternating runs). Native session analyses built a newInferredColumnper model column, while Python's compact analysis shares one object per distinct column. The custom-rule host payload therefore pickled more distinct objects (64.0 MB vs 59.6 MB) and hosts decoded more.Changes
NativeModelAnalysiskeeps oneInferredColumnper distinct column row for the session. Values are unchanged; only object identity is shared. Host payload is now 59.6 MB.custom_rules_cpu_ms: CPU of the custom-rule thread plus finished child processes (the rule hosts, viaos.times; children are 0 on Windows).custom_rules_cpu_msat 1.25x python + 50 ms. The margin is wide because CI noise for this phase is unproven and the rule hosts share cores; the deterministic column-object count in the parity test is what pins the interning, so the gate only catches gross regressions.Changed expectations, each new:
custom_rules_cpu_msin compile JSON timing keys and in the dense cold E2E (> 0).Verification
custom_rules_cpu_msratio, dense 3000, same machine: 1.151 before; after 1.007, 0.998, 0.996, 1.003, 1.005 (5 comparisons). The 1.144 sabotage is caught by the parity count, not this gate.make check-ci; hygiene.