Skip to content

refactor(dfir_lang): DFIR singleton references, convert singleton state to plain local variables#2829

Draft
MingweiSamuel wants to merge 1 commit intomainfrom
mingwei/singleton-refs-dfir
Draft

refactor(dfir_lang): DFIR singleton references, convert singleton state to plain local variables#2829
MingweiSamuel wants to merge 1 commit intomainfrom
mingwei/singleton-refs-dfir

Conversation

@MingweiSamuel
Copy link
Copy Markdown
Member

No description provided.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Apr 30, 2026

Deploying hydro with  Cloudflare Pages  Cloudflare Pages

Latest commit: f959a3b
Status: ✅  Deploy successful!
Preview URL: https://303fe27f.hydroflow.pages.dev
Branch Preview URL: https://mingwei-singleton-refs-dfir.hydroflow.pages.dev

View logs

@MingweiSamuel MingweiSamuel changed the title Move DFIR singleton handling from RefCell to plain local variables refactor(dfir_lang): DFIR singleton references, convert singleton state to plain local variables Apr 30, 2026
MingweiSamuel added a commit that referenced this pull request Apr 30, 2026
Replace `RefCell<T>` with plain `let mut` local variables for singleton
state in DFIR operator codegen. Since subgraphs run sequentially in
topological order and singleton references create ordering edges, there
is never concurrent access — the RefCell runtime borrow checking was
unnecessary overhead.

Updated 16 files: process_singletons.rs, meta_graph.rs, 13 operator
codegen files (fold, fold_keyed, fold_no_replay, reduce, reduce_keyed,
reduce_no_replay, scan, scan_async_blocking, state_by, persist, prefix,
repeat_n), lattice_bimorphism operator, and LatticeBimorphismPull runtime.

Co-authored-by: Infinity 🤖 <infinity@hydro.run>
PR: #2829
@MingweiSamuel MingweiSamuel force-pushed the mingwei/singleton-refs-dfir branch from 21aa0d4 to 87a6b4f Compare April 30, 2026 23:18
@MingweiSamuel MingweiSamuel force-pushed the mingwei/delete-state-api-usage branch from c56d8d8 to 37ebe2e Compare April 30, 2026 23:18
MingweiSamuel added a commit that referenced this pull request May 1, 2026
Replace `RefCell<T>` with plain `let mut` local variables for singleton
state in DFIR operator codegen. Since subgraphs run sequentially in
topological order and singleton references create ordering edges, there
is never concurrent access — the RefCell runtime borrow checking was
unnecessary overhead.

Updated 16 files: process_singletons.rs, meta_graph.rs, 13 operator
codegen files (fold, fold_keyed, fold_no_replay, reduce, reduce_keyed,
reduce_no_replay, scan, scan_async_blocking, state_by, persist, prefix,
repeat_n), lattice_bimorphism operator, and LatticeBimorphismPull runtime.

Co-authored-by: Infinity 🤖 <infinity@hydro.run>
PR: #2829
@MingweiSamuel MingweiSamuel force-pushed the mingwei/delete-state-api-usage branch from 37ebe2e to af90c89 Compare May 1, 2026 16:43
@MingweiSamuel MingweiSamuel force-pushed the mingwei/singleton-refs-dfir branch from 87a6b4f to 5a31e0c Compare May 1, 2026 16:43
MingweiSamuel added a commit that referenced this pull request May 1, 2026
Replace `RefCell<T>` with plain `let mut` local variables for singleton
state in DFIR operator codegen. Since subgraphs run sequentially in
topological order and singleton references create ordering edges, there
is never concurrent access — the RefCell runtime borrow checking was
unnecessary overhead.

Updated 16 files: process_singletons.rs, meta_graph.rs, 13 operator
codegen files (fold, fold_keyed, fold_no_replay, reduce, reduce_keyed,
reduce_no_replay, scan, scan_async_blocking, state_by, persist, prefix,
repeat_n), lattice_bimorphism operator, and LatticeBimorphismPull runtime.

Co-authored-by: Infinity 🤖 <infinity@hydro.run>
PR: #2829
@MingweiSamuel MingweiSamuel force-pushed the mingwei/singleton-refs-dfir branch from 5a31e0c to 2f4bc58 Compare May 1, 2026 18:02
@MingweiSamuel MingweiSamuel force-pushed the mingwei/delete-state-api-usage branch from af90c89 to 094abd4 Compare May 1, 2026 18:02
MingweiSamuel added a commit that referenced this pull request May 1, 2026
Replace `RefCell<T>` with plain `let mut` local variables for singleton
state in DFIR operator codegen. Since subgraphs run sequentially in
topological order and singleton references create ordering edges, there
is never concurrent access — the RefCell runtime borrow checking was
unnecessary overhead.

Updated 16 files: process_singletons.rs, meta_graph.rs, 13 operator
codegen files (fold, fold_keyed, fold_no_replay, reduce, reduce_keyed,
reduce_no_replay, scan, scan_async_blocking, state_by, persist, prefix,
repeat_n), lattice_bimorphism operator, and LatticeBimorphismPull runtime.

Co-authored-by: Infinity 🤖 <infinity@hydro.run>
PR: #2829
@MingweiSamuel MingweiSamuel force-pushed the mingwei/singleton-refs-dfir branch from 2f4bc58 to 339c46f Compare May 1, 2026 18:44
Base automatically changed from mingwei/delete-state-api-usage to main May 1, 2026 21:33
Replace `RefCell<T>` with plain `let mut` local variables for singleton
state in DFIR operator codegen. Since subgraphs run sequentially in
topological order and singleton references create ordering edges, there
is never concurrent access — the RefCell runtime borrow checking was
unnecessary overhead.

Updated 16 files: process_singletons.rs, meta_graph.rs, 13 operator
codegen files (fold, fold_keyed, fold_no_replay, reduce, reduce_keyed,
reduce_no_replay, scan, scan_async_blocking, state_by, persist, prefix,
repeat_n), lattice_bimorphism operator, and LatticeBimorphismPull runtime.

Co-authored-by: Infinity 🤖 <infinity@hydro.run>
PR: #2829
@MingweiSamuel MingweiSamuel force-pushed the mingwei/singleton-refs-dfir branch from 339c46f to f959a3b Compare May 1, 2026 22:48
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.

1 participant