Skip to content

Pass preprocessed_columns directly to seq_of_component_size#449

Draft
noa-starkware wants to merge 1 commit intonoa/let-else-seq-of-component-sizefrom
noa/narrower-arg-seq-of-component-size
Draft

Pass preprocessed_columns directly to seq_of_component_size#449
noa-starkware wants to merge 1 commit intonoa/let-else-seq-of-component-sizefrom
noa/narrower-arg-seq-of-component-size

Conversation

@noa-starkware
Copy link
Copy Markdown
Contributor

Summary

  • seq_of_component_size now takes &HashMap<PreProcessedColumnId, Var> instead of &mut CompositionConstraintAccumulator
  • The function only needs the preprocessed columns map — passing the full accumulator was over-broad
  • All 17 call sites updated to pass &acc.preprocessed_columns

Stacks on #448. Part of audit cleanup (ilya/audit2 TODO comments).

🤖 Generated with Claude Code

@cursor
Copy link
Copy Markdown

cursor bot commented Apr 12, 2026

PR Summary

Low Risk
Low risk refactor that narrows a helper’s inputs and updates call sites; main risk is mismatched preprocessed-column plumbing causing incorrect seq_* lookup at runtime.

Overview
Refactors seq_of_component_size (in both cairo_air and circuit_air) to take only &HashMap<PreProcessedColumnId, Var> instead of the full CompositionConstraintAccumulator, and switches internal lookups to use the passed map.

Updates all affected components/gates to call seq_of_component_size(context, component_data, &acc.preprocessed_columns) so the helper no longer requires (or implies) mutable access to the accumulator.

Reviewed by Cursor Bugbot for commit 660bde1. Bugbot is set up for automated code reviews on this repo. Configure here.

@reviewable-StarkWare
Copy link
Copy Markdown
Collaborator

This change is Reviewable

@noa-starkware noa-starkware self-assigned this Apr 12, 2026
@noa-starkware noa-starkware force-pushed the noa/narrower-arg-seq-of-component-size branch from e628619 to 660bde1 Compare April 12, 2026 13:46
@noa-starkware noa-starkware marked this pull request as draft April 12, 2026 13:46
@noa-starkware noa-starkware force-pushed the noa/let-else-seq-of-component-size branch from 2592fbc to 391971e Compare April 12, 2026 13:48
Instead of taking the full CompositionConstraintAccumulator, only take
the preprocessed columns map that the function actually needs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@noa-starkware noa-starkware force-pushed the noa/narrower-arg-seq-of-component-size branch from 660bde1 to 36dc977 Compare April 12, 2026 13:49
Copy link
Copy Markdown
Contributor

@ilyalesokhin-starkware ilyalesokhin-starkware left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

@ilyalesokhin-starkware reviewed 19 files and all commit messages, and made 1 comment.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on az-starkware).

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.

3 participants