Conversation
3 tasks done
Nothing in the stage pipeline, facade, devtools or tests reaches the legacy search any more (#631, #633). Delete it and what only it used: in logical-optimizer the replacement/grouping/rollup/rewrite/ exact-composition/explanation/reconciliation/top-k-reuse strategies, search_workload*, accuracy propagation and allocation, and EstimatorAccuracy; in plan-selection the CostModel trait, DefaultCostModel, empirical_cost, recurrence's CSE decision and PlanningModels.cost. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…cy search #621's Stage 4 sizing called pass1::replacement::sketch_state_bytes, which this PR deletes; compute UnivMon's per-layer counter and heap bytes in plan-selection directly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
zzylol
force-pushed
the
stack/cleanup-8-port-legacy-callers
branch
from
October 5, 2026 06:21
94a6d35 to
b0b37f1
Compare
zzylol
force-pushed
the
stack/cleanup-9-delete-legacy-search
branch
from
October 5, 2026 06:21
f9fc726 to
a7a07d8
Compare
This was referenced Oct 5, 2026
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.
Stack: #574 → #620 → #618 → #621 → #627 → #625 → #628 → #632 → #634 → #616 → #617 → #622 → #624 → #629 → #630 → #631 → #633 → #635 → #636 → #637
Rebased: added
fix: integrate with #621: #621's Stage 4 UnivMon sizing usedpass1::replacement::sketch_state_bytes, which this PR deletes; plan-selection now computes UnivMon's per-layer counter and heap bytes itself. DeletingEstimatorAccuracyalso drops its #627answersforwarder; the trait-levelanswersstays.Problem
After #631 (Stage 1's helpers moved out) and #633 (callers ported), nothing in the stage pipeline, the facade, the devtools or the tests reaches the legacy replacement search or the
CostModelit ranked with. Q68 (a) deletes them.Changes
logical-optimizer (-16k lines):
pass1/{replacement, grouping, exact_composition, rollup, rewrite, explanation, function_rules}.rsandpass2/{reconciliation, topk_reuse}.rs. This takesASAPStrategies,search_workload*,CandidateLogicalASAPDAGs,GlobalSelection,ReplacementStrategyand the other strategies,explain_replacements,retain_exact,Matcher,posterior_aware_size_paramsandsketch_state_bytes.accuracy/{composition, allocation}.rsandEstimatorAccuracy.AccuracyModellosespropagateandexact_operation_rule. That part of step 8 (Q53) is done here becauseexact_operation_ruletakes the deletedExactOperationandpropagatedelegates to the deleted composition rules; step 8 only moves the trait.QuantileInputDomain::supports_ddsketchdeleted (only the DDSketch ratio propagation used it).realize_keyed_additive_summary_inputreturnsOption<PhysicalSummaryInput>. With the legacy rule table gone, nothing read its "unsupported" reason; the reasons stay as comments.maintained_population.rskeepsMaintainedPopulationStrategy::candidate, which executor and frontend tests call directly. Only itsReplacementStrategyimpl, and the assertion of its test that usedsearch_workload_with, are removed.asap-typesand the planner facade now point at Stage 1.plan-selection:
cost/{cost_model, empirical_cost, empirical_resources}.rs: theCostModeltrait (defined onReplacementSubDAG/TargetSubDAG/ExactComposition),DefaultCostModel, the CSE share/recompute and exact-composition cost inputs, and evidence-based cost.cost/recurrence.rskeeps only what Stage 3 uses:evaluation_rate_of,EvaluationRateandRecurrenceError::InvalidInterval. The legacydecideis deleted, withRecurrenceProfile,RecurrenceCostExplanation,RootRecurrence,CostRate,Horizon,UpdateRate,total_costandupdate_rate_from_data_workload(onlydecideandCostModelused them).PlanningModels.costandwith_costremoved;PlanningModels::newtakes(accuracy, evidence).Tests:
planner/tests/summary_sharing.rsdrops thePreferSketchcost model and the#[ignore]d test that needed it;stage_pipeline_shares_one_kll_sized_for_the_strictest_consumercovers the stage pipeline's version. The legacy modules' own unit tests go with them.Kept, but now unread by any stage (follow-up candidates, not part of the approved list):
PlanningModels.evidence,AccuracyEvidenceProvider,NoAccuracyEvidence,WorkloadAccuracyEvidence,EstimatorContract,QuantileInputDomain,PropagationStats(the Hydra local guarantee still uses it) andhll::ClassicHllConfidence.cost::{physical_handoff_cost, storage_io, query_physical_lowering}stay as deployment-priced profiles with their own tests.Stacked on #633.
Test plan
cargo fmt --all --checkcargo clippy --workspace --all-targets --all-features --locked -- -D warningscargo test --workspace --locked: 1280 passed, 0 failed, 14 ignored (after the rebase on main d4869a7; was 1256 passed, 22 ignored)🤖 Generated with Claude Code