← Advanced course and all videos

Video 46 of 53 · 3:29 · Recognition and exact verification

Policy gates and fixed exact arms

In this video

  1. 0:00 · Introduction
  2. 0:19 · A dispatcher is part of the program
  3. 1:11 · Core explanation
  4. 2:33 · Confirmation requires a frozen candidate
  5. 3:18 · Direct takeaways

Caption transcript

Show transcript
This overview explains how dispatch, source transfer, cost-policy fitting, and compiled policies interact in C17 through C20. An aggregate improvement can coexist with a per-case failure, and a retrospective replay is not fresh confirmation. A router that selects an exact method is itself a program. In this fictional example, feature extraction costs two units, dispatch costs one, and the chosen exact arm costs ten. The caller pays thirteen units for the complete route. If every leaf of the decision tree chooses that same arm, evaluating the features cannot change the decision. Replacing the tree with a constant selection removes unnecessary feature work while preserving the chosen method. Follow two inputs down different paths. They reach different leaves but select the same control. This makes the redundancy concrete. Folding the constant decision is valid only after confirming that every relevant path has the same result and required side effects are preserved. C17 adds a task dispatcher around exhaustive and screened exact arms. C18 changes the source cohort. C19 separates development, validation and confirmation for fitting a cost policy. C20 compiles the frozen policy when its learned tree reduces to a constant screened choice. In a conceptual task, a dispatcher examines features, chooses screening and verifies the selected artifact. If it always chooses screening, the features and branch can become pure overhead. Constant-folding that frozen choice removes the decision path while preserving the selected exact arm. A separate fresh test is still needed to establish performance outside the cohort that motivated the change. The retained sequence includes aggregate improvements, a tiny-case tail failure, independent-source evidence and a retrospective same-machine replay. A retrospective replay is not a fresh confirmation simply because the code is new. None permits dropping exact reconstruction or changing a per-case gate after observing failures. Development evidence can guide revisions. Before confirmation, freeze the rule, source identities, and acceptance gates so that the test has a stable object to evaluate. A fresh eligible cohort tests the frozen rule under the declared criteria. Aggregate performance and bad-case limits can answer different questions, so retain both when they are part of the gate. Replaying the same old cohort can verify reproducibility. It does not create fresh source-family evidence. A no-op or constant dispatcher can be safe and exact while remaining unpromoted under the actual frozen performance criteria. Keep reconstruction checks and frozen per-case gates intact. Compare a constant policy with invoking the same fixed arm directly.