Closed
Labels
engineIssues with the rust-based simulation engineenhancementNew feature or requestltmLoops that Matter (LTM) analysis subsystem
Description
LTM now scores a bare reducer argument in a per-element equation as the row it reads (#1087): with m[d1, d2], slot[a] = SUM(m) * 0.001 is scored exactly like SUM(m[a, *]) * 0.001.
What is left is follow-through.
- Docs and comments still describe the old behavior, declining the edge with a warning:
docs/design/ltm--loops-that-matter.md, "Two executed reads are declined rather than described" (calls this "the tracked follow-up")src/simlin-engine/src/ltm_agg.rs, comments near lines 1066, 2870 and 2900src/simlin-engine/CLAUDE.md, the LTM "No silent wrong numbers" rule, which cites the scoring test as evidence of a decline
- Slots with different reducers and bare arguments (
slot[a] = SUM(m),slot[b] = MEAN(m)) have no loop-score test.
The only mixed-reducer test (per_element_arrayed_target_mints_one_agg_per_element_reducerinltm_agg_tests.rs) uses explicit[*]and checks only that the helper nodes are created.
Fix
Rewrite the stale text to describe current behavior, check whether the bare-argument decline in unhoisted_reducer_source_read can still fire (delete it if not), and add the mixed-reducer row beside the existing scoring tests.
Pointers
src/simlin-engine/src/compiler/fragment.rs:FragmentInput::elementwise_targetsrc/simlin-engine/src/ltm_elementwise_tests.rs:a_slots_bare_reducer_argument_is_scored_as_the_row_it_readssrc/simlin-engine/src/ltm_agg.rs:unhoisted_reducer_source_read,reducer_reads_source_bare
Metadata
Metadata
Assignees
Labels
engineIssues with the rust-based simulation engineenhancementNew feature or requestltmLoops that Matter (LTM) analysis subsystem
Activity
[-]ltm: bare reducer argument in a per-element (Ast::Arrayed) slot is declined loudly -- spell the slot's pinned element so the hoisted node is per slot[/-][+]ltm: bare reducer argument in a per-element equation is not scored[/+][-]ltm: bare reducer argument in a per-element equation is not scored[/-][+]ltm: docs still say a bare reducer argument in a slot is declined[/+]bpowers commentedon Oct 12, 2026
Closing: fixed on main by #1087. 12b1df5 corrects the docs and comments and adds
slots_with_different_reducers_of_a_bare_argument_are_scored_as_their_rows. The old decline stays: it can still be reached when a slot's lowered equation is unavailable (for example another element of the same variable reads an undeclared name); that was established by reading the code, not by a test.