Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
70d7e28
Generalize int-proxy tokens from u64 to Copy + Ord types
frankmcsherry Jul 22, 2026
e197207
Bring both proxy tactics to windowed, streaming operation
frankmcsherry Jul 22, 2026
0adc323
Add the graph reference backend, and the contract fixes it forced
frankmcsherry Jul 22, 2026
05c4811
Bytes backend, and the adversarial-review fix wave
frankmcsherry Jul 22, 2026
c1b9955
Benchmark: proxy tactics vs native, value-token instantiation
frankmcsherry Jul 22, 2026
6a65ced
Partial-order pending test, and the shared test scaffold
frankmcsherry Jul 22, 2026
9a7a126
Single-moment fast path in the proxy reduce harness
frankmcsherry Jul 22, 2026
cdaec9d
Randomized differential test for the reduce harness
frankmcsherry Jul 23, 2026
a36dda8
Bench the incumbents: cursor tactics vs proxy on identical storage
frankmcsherry Jul 23, 2026
b52cac6
Cross-by-emit and window-buffer recycling
frankmcsherry Jul 23, 2026
3945cb8
Unit-owned Sink: fix cross-unit output contamination in absorb
frankmcsherry Jul 23, 2026
1bc0752
SCC with proxy joins: the first in-dataflow exercise, at parity
frankmcsherry Jul 23, 2026
fb06f91
Prune the validation apparatus to its property core
frankmcsherry Jul 23, 2026
ed19240
scc_proxy: SCC_STAGGER mode, pointing the #801 trigger at proxy joins
frankmcsherry Jul 23, 2026
50a32e2
Re-privatize the cursor tactic modules
frankmcsherry Jul 23, 2026
f1a0310
Thin to substrate: remove the SCC example in favor of the Corgi gate
frankmcsherry Jul 23, 2026
6c5a1a5
Review fixes: assert finish() batch count; exercise the wave path
frankmcsherry Jul 23, 2026
bff410b
JoinUnit: give the fields their structure
frankmcsherry Jul 23, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 18 additions & 16 deletions differential-dataflow/src/operators/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,13 @@ impl<T: Lattice + Clone + Ord> TimeHistory<T> {
/// `emit` receives every produced `(id0, id1, joined time, multiplied diff)`. Both histories
/// must be pre-loaded (`load`/`load_iter`) and are fully drained. For small histories a plain
/// cross product is cheaper; callers should gate on size.
pub fn bilinear_wave<V, T, R0, R1, RO>(
h0: &mut ValueHistory<V, T, R0>,
h1: &mut ValueHistory<V, T, R1>,
mut emit: impl FnMut(V, V, T, RO),
pub fn bilinear_wave<V0, V1, T, R0, R1, RO>(
h0: &mut ValueHistory<V0, T, R0>,
h1: &mut ValueHistory<V1, T, R1>,
mut emit: impl FnMut(V0, V1, T, RO),
) where
V: Copy + Ord,
V0: Copy + Ord,
V1: Copy + Ord,
T: Ord + Clone + Lattice,
R0: Semigroup + Multiply<R1, Output = RO> + Clone,
R1: Semigroup + Clone,
Expand Down Expand Up @@ -180,11 +181,11 @@ pub fn tile_descriptions<T: Timestamp + Lattice>(
}

/// A one-key view into an input presentation: the read-only arguments [`discover_times`] needs
/// about a single key — its slice `[i0, i1)` of the merged `(id, time, diff)` run `p_in` and
/// about a single key — its slice `[i0, i1)` of the merged `(token, time, diff)` run `p_in` and
/// the carried `pending` times.
pub struct KeyView<'a, T, RIn> {
/// The presented `((key_hash, value_id), time, diff)` run the key's records live in.
pub p_in: &'a [((u64, u64), T, RIn)],
pub struct KeyView<'a, G, I, T, RIn> {
/// The presented `((group, token), time, diff)` run the key's records live in.
pub p_in: &'a [((G, I), T, RIn)],
/// The key's first record.
pub i0: usize,
/// One past the key's last record.
Expand All @@ -205,17 +206,17 @@ fn update_meet<T: Lattice + Clone>(meet: &mut Option<T>, other: Option<&T>) {

/// Reusable per-key scratch for [`discover_times`]: held once and threaded through every key,
/// so replays and time buffers are cleared and refilled rather than reallocated per key.
pub struct DiscoverScratch<T, RIn> {
pub struct DiscoverScratch<I, T, RIn> {
batch_replay: TimeHistory<T>,
input_replay: ValueHistory<u64, T, RIn>,
input_replay: ValueHistory<I, T, RIn>,
output_replay: TimeHistory<T>,
synth: Vec<T>,
times_current: Vec<T>,
temporary: Vec<T>,
meets: Vec<T>,
}

impl<T: Timestamp + Lattice, RIn: Semigroup + Clone> DiscoverScratch<T, RIn> {
impl<I: Copy + Ord, T: Timestamp + Lattice, RIn: Semigroup + Clone> DiscoverScratch<I, T, RIn> {
/// Fresh scratch; hold one per retire and thread it through every key.
pub fn new() -> Self {
DiscoverScratch {
Expand All @@ -230,7 +231,7 @@ impl<T: Timestamp + Lattice, RIn: Semigroup + Clone> DiscoverScratch<T, RIn> {
}
}

impl<T: Timestamp + Lattice, RIn: Semigroup + Clone> Default for DiscoverScratch<T, RIn> {
impl<I: Copy + Ord, T: Timestamp + Lattice, RIn: Semigroup + Clone> Default for DiscoverScratch<I, T, RIn> {
fn default() -> Self { Self::new() }
}

Expand All @@ -246,15 +247,16 @@ impl<T: Timestamp + Lattice, RIn: Semigroup + Clone> Default for DiscoverScratch
/// consolidated view is unsound: compaction may advance a history record onto a novel time,
/// where consolidation cancels the novel update and its interesting time is missed.
#[allow(clippy::too_many_arguments)]
pub fn discover_times<T, RIn>(
key: KeyView<'_, T, RIn>,
pub fn discover_times<G, I, T, RIn>(
key: KeyView<'_, G, I, T, RIn>,
seed_times: impl Iterator<Item = T>,
out_times: impl Iterator<Item = T>,
upper: &Antichain<T>,
scratch: &mut DiscoverScratch<T, RIn>,
scratch: &mut DiscoverScratch<I, T, RIn>,
moments: &mut Vec<T>,
pended: &mut Vec<T>,
) where
I: Copy + Ord,
T: Timestamp + Lattice,
RIn: Semigroup + Clone,
{
Expand Down
4 changes: 2 additions & 2 deletions differential-dataflow/src/operators/int_proxy/history.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//! Time-ordered replay of proxy update histories, with meet-advancement.

/// A value history suitable for integer proxy values.
pub(in crate::operators) type IdHistory<T, R> = crate::operators::ValueHistory<u64, T, R>;
/// A value history over proxy value tokens.
pub(in crate::operators) type IdHistory<I, T, R> = crate::operators::ValueHistory<I, T, R>;

Loading
Loading