Skip to content

Commit ddb6f97

Browse files
cleanup: remove no-op schedule_subgraph(false) calls, fix formatting
Remove all `schedule_subgraph(false)` calls from operator codegen — these were no-ops since `schedule_subgraph` only acts when `is_external` is `true`. Clean up the `schedule_subgraph(true)` call in meta_graph.rs formatting. Co-authored-by: Infinity 🤖 <infinity@hydro.run>
1 parent bc86e4d commit ddb6f97

12 files changed

Lines changed: 13 additions & 17 deletions

dfir_lang/src/graph/meta_graph.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1548,13 +1548,9 @@ impl DfirGraph {
15481548
#( #subgraph_blocks )*
15491549

15501550
// For non-lazy defer_tick: if any deferred buffer has data,
1551-
// signal that another tick should run (sets can_start_tick).
1552-
// Inline DFIR doesn't dynamically schedule subgraph IDs, so the
1553-
// subgraph ID here is a meaningless placeholder.
1551+
// signal that another tick should run.
15541552
if false #( || !#defer_tick_buf_idents.is_empty() )* {
1555-
#df.schedule_subgraph(
1556-
true,
1557-
);
1553+
#df.schedule_subgraph(true);
15581554
}
15591555

15601556
// End-of-tick state reset (e.g. 'tick persistence).

dfir_lang/src/graph/ops/cross_join_multiset.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ pub const CROSS_JOIN_MULTISET: OperatorConstraints = OperatorConstraints {
112112
.then(|| {
113113
quote_spanned! {op_span=>
114114
// Reschedule the subgraph lazily to ensure replay on later ticks.
115-
#context.schedule_subgraph(false);
115+
116116
}
117117
});
118118
let write_iterator_after = quote_spanned! {op_span=>

dfir_lang/src/graph/ops/fold.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ pub const FOLD: OperatorConstraints = OperatorConstraints {
141141

142142
let write_iterator_after = if let Persistence::Static | Persistence::Tick = persistence {
143143
quote_spanned! {op_span=>
144-
#context.schedule_subgraph(false);
144+
145145
}
146146
} else {
147147
Default::default()

dfir_lang/src/graph/ops/fold_keyed.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ pub const FOLD_KEYED: OperatorConstraints = OperatorConstraints {
262262
Persistence::None | Persistence::Tick | Persistence::Loop => Default::default(),
263263
Persistence::Static | Persistence::Mutable => quote_spanned! {op_span=>
264264
// Reschedule the subgraph lazily to ensure replay on later ticks.
265-
#context.schedule_subgraph(false);
265+
266266
},
267267
};
268268

dfir_lang/src/graph/ops/join.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ pub const JOIN: OperatorConstraints = OperatorConstraints {
214214
if persistences[0] == Persistence::Static || persistences[1] == Persistence::Static {
215215
quote_spanned! {op_span=>
216216
// TODO: Probably only need to schedule if #*_borrow.len() > 0?
217-
#context.schedule_subgraph(false);
217+
218218
}
219219
} else {
220220
quote_spanned! {op_span=>}

dfir_lang/src/graph/ops/join_fused.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ pub const JOIN_FUSED: OperatorConstraints = OperatorConstraints {
174174
if persistences[0] == Persistence::Static || persistences[1] == Persistence::Static {
175175
quote_spanned! {op_span=>
176176
// TODO: Probably only need to schedule if #*_borrow.len() > 0?
177-
#context.schedule_subgraph(false);
177+
178178
}
179179
} else {
180180
quote_spanned! {op_span=>}

dfir_lang/src/graph/ops/join_fused_lhs.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ pub const JOIN_FUSED_LHS: OperatorConstraints = OperatorConstraints {
131131
if persistences[0] == Persistence::Static || persistences[1] == Persistence::Static {
132132
quote_spanned! {op_span=>
133133
// TODO: Probably only need to schedule if #*_borrow.len() > 0?
134-
#context.schedule_subgraph(false);
134+
135135
}
136136
} else {
137137
quote_spanned! {op_span=>}

dfir_lang/src/graph/ops/persist.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ pub const PERSIST: OperatorConstraints = OperatorConstraints {
135135
};
136136

137137
let write_iterator_after = quote_spanned! {op_span=>
138-
#context.schedule_subgraph(false);
138+
139139
};
140140

141141
Ok(OperatorWriteOutput {

dfir_lang/src/graph/ops/persist_mut.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ pub const PERSIST_MUT: OperatorConstraints = OperatorConstraints {
114114
};
115115

116116
let write_iterator_after = quote_spanned! {op_span=>
117-
#context.schedule_subgraph(false);
117+
118118
};
119119

120120
Ok(OperatorWriteOutput {

dfir_lang/src/graph/ops/persist_mut_keyed.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ pub const PERSIST_MUT_KEYED: OperatorConstraints = OperatorConstraints {
127127
};
128128

129129
let write_iterator_after = quote_spanned! {op_span=>
130-
#context.schedule_subgraph(false);
130+
131131
};
132132

133133
Ok(OperatorWriteOutput {

0 commit comments

Comments
 (0)