A cycle start with no statement number is still a cycle #718

Manually merged
binjovi-bot merged 4 commits from l2f-cycle-prologue into trunk 2026-11-04 13:28:08 +00:00
Owner

A cycle start with no statement number is still a cycle

The compiler gave the cycle start of the main procedure of SC-ILE/TFOR-STRIPPED
and of both SC-ILE/SCALE-AMBIGUITY twins no statement number: the entry code,
the cycle start and its compiler routines are one run of operations before the
first numbered statement. statementOf found nothing for the jump back to the
start of the detail calculations, so that jump stayed block_owner, and the
compiler routines after the cycle end stayed remaining_effects.

  • rpg_cycle.zig: prologueOf is the run before the first numbered
    statement; totals uses it when statementOf finds nothing, so the cycle
    end is proved. returnsBare is the final return (labels, a jump over
    labels, 26) without the copy of X onto itself, which the compiler also
    drops when it drops statement 1000002.
  • rpg_cycle_template.zig: unnumberedPrologue proves the cycle start
    template over that run, from the first 27 A; 37 45 72 B. rpg_specs.zig
    analyze takes it when the numbered forms do not apply (one branch).
  • rpg_cycle_end.zig: the suffix of the body that no routine proved is the
    bare return when every jump into its labels comes from the entry code, the
    cycle start or the body.

Public result: TFOR-STRIPPED statement 1500 and SCALE-AMBIGUITY statements 600
(both twins) recover; the SCALE statement 500 stays on decimal_positions.
twins-diff: no recovered group fell. emit-diff: no row worse, three rows
clean (failures 385 to 382). No effect on the held-out control_flow line
(oracle: unchanged). Tests: src/rpg_cycle_prologue_test.zig.

Not done, named next target: operation 33 (push the address of a symbol) fails
in the cycle-start statements of r7h-prt-ofl, r7h-prt-ho, r7h-prt-ind,
r7h-prt-one, r7h-prt-two and ACCESS (110 111; 27 K; 37; 33 X; 35 T; 18, an
address stored into a temporary; arm 33 requires a data symbol and X is not
one). FLOW/lx-total (SETON LR fused with the total calculation) is not done;
its ADD statements stop on decimal_positions.

Edit outside the lane files (src/core/rpg_source_unused.zig, L4, merged and idle; coordinator agreed): only the guard below. With the cycle body proved, the static initialization stores the zero default of
an unused packed field, and rpg_source_unused.proved took that value as proof
of a source declaration with an unknown scale, so scale-one lost its spare
declaration. A zero packed default is no proof now (defaultPacked).

Gates

{"checks":{"net_statements":0},"census":{"statuses":{"recovered":645,"partial":0,"unresolved":0},"regressions":0,"newly_recovered":0},"golden":"golden floor 173 ceiling 0 <= dump 173/5/0","legend":"regenerated","emit":{"worse":[],"better":3,"newly_clean":3,"clean_delta":3,"base":322,"new":325},"twins":{"groups":468,"recovered":460,"regressions":[],"newly":0},"allgroups":{"regressions":[],"newly":["savf/SC-ILE/SCALE-AMBIGUITY/scale-one/archive.savf 1","savf/SC-ILE/SCALE-AMBIGUITY/scale-two/archive.savf 1","savf/SC-ILE/TFOR-STRIPPED/archive.savf 1"],"worse":[]},"full_check":{"exit":0,"seconds":935}}
## A cycle start with no statement number is still a cycle The compiler gave the cycle start of the main procedure of SC-ILE/TFOR-STRIPPED and of both SC-ILE/SCALE-AMBIGUITY twins no statement number: the entry code, the cycle start and its compiler routines are one run of operations before the first numbered statement. `statementOf` found nothing for the jump back to the start of the detail calculations, so that jump stayed `block_owner`, and the compiler routines after the cycle end stayed `remaining_effects`. - `rpg_cycle.zig`: `prologueOf` is the run before the first numbered statement; `totals` uses it when `statementOf` finds nothing, so the cycle end is proved. `returnsBare` is the final return (labels, a jump over labels, `26`) without the copy of X onto itself, which the compiler also drops when it drops statement 1000002. - `rpg_cycle_template.zig`: `unnumberedPrologue` proves the cycle start template over that run, from the first `27 A; 37 45 72 B`. `rpg_specs.zig` analyze takes it when the numbered forms do not apply (one branch). - `rpg_cycle_end.zig`: the suffix of the body that no routine proved is the bare return when every jump into its labels comes from the entry code, the cycle start or the body. Public result: TFOR-STRIPPED statement 1500 and SCALE-AMBIGUITY statements 600 (both twins) recover; the SCALE statement 500 stays on `decimal_positions`. twins-diff: no recovered group fell. emit-diff: no row worse, three rows clean (failures 385 to 382). No effect on the held-out control_flow line (oracle: unchanged). Tests: `src/rpg_cycle_prologue_test.zig`. Not done, named next target: operation 33 (push the address of a symbol) fails in the cycle-start statements of r7h-prt-ofl, r7h-prt-ho, r7h-prt-ind, r7h-prt-one, r7h-prt-two and ACCESS (`110 111; 27 K; 37; 33 X; 35 T; 18`, an address stored into a temporary; arm 33 requires a data symbol and X is not one). FLOW/lx-total (SETON LR fused with the total calculation) is not done; its ADD statements stop on `decimal_positions`. Edit outside the lane files (src/core/rpg_source_unused.zig, L4, merged and idle; coordinator agreed): only the guard below. With the cycle body proved, the static initialization stores the zero default of an unused packed field, and `rpg_source_unused.proved` took that value as proof of a source declaration with an unknown scale, so scale-one lost its `spare` declaration. A zero packed default is no proof now (`defaultPacked`). ## Gates ``` {"checks":{"net_statements":0},"census":{"statuses":{"recovered":645,"partial":0,"unresolved":0},"regressions":0,"newly_recovered":0},"golden":"golden floor 173 ceiling 0 <= dump 173/5/0","legend":"regenerated","emit":{"worse":[],"better":3,"newly_clean":3,"clean_delta":3,"base":322,"new":325},"twins":{"groups":468,"recovered":460,"regressions":[],"newly":0},"allgroups":{"regressions":[],"newly":["savf/SC-ILE/SCALE-AMBIGUITY/scale-one/archive.savf 1","savf/SC-ILE/SCALE-AMBIGUITY/scale-two/archive.savf 1","savf/SC-ILE/TFOR-STRIPPED/archive.savf 1"],"worse":[]},"full_check":{"exit":0,"seconds":935}} ```
binjovi-bot manually merged commit cc8782599c into trunk 2026-11-04 13:28:08 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sean/sourcerer!718
No description provided.