Skip to content

det: CBSTM03A's PSA -> TCB -> TIOT walk, laid from the stated job step (Part of #5856) - #5868

Merged
squid-protocol merged 6 commits into
mainfrom
churn/5856-20261021T1246Z
Oct 21, 2026
Merged

squid-protocol merged 6 commits into
mainfrom
churn/5856-20261021T1246Z

Conversation

@squid-protocol

@squid-protocol squid-protocol commented Oct 21, 2026 •

Copy link
Copy Markdown
Owner

Part of #5856 (slice 1 of 3: the det side; the oracle and the equivalence case follow).

CardDemo's CBSTM03A (burned) had 5 SET ADDRESS OF (pointers) holes from its PSA -> TCB -> TIOT walk. A batch
program's pointers now go to a z/OS control-block stand-in, laid from the job step the run states (register A2).
It is not a named refusal: the TIOT's contents are facts of the run, like X68's EIBTRNID, and IBM documents the
layout. CBSTM03A now translates 424/424 statements with 0 holes, and it compiles.

What changed

  • det/cobolrt/DetMvs.java (new, rule RT-MVS-CONTROL-BLOCKS):
    • Three blocks, addressed by 8-byte handles (C9): the PSA (NULL = address 0; PSATNEW at X'218' gives the TCB),
      the TCB (TCBTIO at +12 gives the TIOT), and the TIOT. The TIOT is a 24-byte header, then 20-byte DD entries
      (TIOEDDNM +4, UCB token +17..19), then a zero fullword.
    • The step is -Dgitgalaxy.mvs.step=JOB;STEP;PROCSTEP;DD:UCB,DD:NOUCB,....
    • Refused by name at run time: no step stated, a malformed DD, a record laid past the stand-in's fields, pointer
      arithmetic that leaves its block, and a pointer to no block.
    • It lives at the cobolrt root, not batch/, because runtime_files drops batch/ for standalone projects.
  • gen.py:
    • In batch, SET ADDRESS OF rec TO ptr emits DetMvs.setAddress. The TO ADDRESS OF forms are still refused.
    • Pointer arithmetic goes through pointer_lane(): DetCics in CICS, DetMvs in batch.
    • New: COMPUTE v = v +/- n on a pointer's numeric view is the same advance as ADD / SUBTRACT (CICS too).
  • program.py:
    • A plain elementary POINTER that REDEFINES a BINARY S9(n) (CBSTM03A's TIOT-INDEX over BUMP-TIOT) makes
      that numeric item its view.
    • A second REDEFINES of the view is refused ("a pointer a REDEFINES overlays").
  • Register A2 (family A, ASSUMED, cites IBM's MVS Data Areas), plus the rule, family and document in
    cobolrt_rules.json.
  • tests/cobol_mainframe/test_tiot_walk_5856.py (16 tests, 2.7 s):
    • Translates CBSTM03A's real walk whole.
    • Compiles and runs the walk on the CREASTMT STEP040 step: the job / step / DD lines, with valid and null UCB.
    • Covers a one-DD step and the ADD / SUBTRACT / COMPUTE forms.
    • Covers every runtime refusal and the translator holes that stay holes.

Gates

  • det_port.py check: 161/161 ports unchanged.
  • det_survey --corpus carddemo: 40 programs whole, 4 with holes, 0 refused; no pointer reason is left.
  • test_pointer_lane_4771 / _5042 / test_cobolrt_rules pass; register.py --check, register.py audit --ci and
    cobolrt_rules.py --check are clean.
  • audit_check.py is all clear. pr_gates --fast passes 7/7 and --ratchets passes 8/8. time_ratchet check
    passes.
  • No golden impact: the change is det only.

Not in this PR

  • Slice 2, the oracle: a C stand-in (ggtiot.c) laying the same blocks from the same step, plus an equivalence.py
    lowering. Linux cannot map page 0, and the 4-byte BINARY view of an 8-byte pointer needs care.
  • Slice 3: CBSTM03A's equivalence case (step from CREASTMT STEP040), then evidence.py prove.
  • docs/language_status/det_survey.md is a dated snapshot of every corpus (2026-10-02) and is not regenerated here.

Class table

Class: batch-program pointer idioms over z/OS control blocks (SET ADDRESS OF / pointer arithmetic that det refused as pointers).

Member Status Evidence
SET ADDRESS OF rec TO ptr in batch (PSA -> TCB -> TIOT) handled here test_tiot_walk_5856; CBSTM03A 0 holes
ADD / SUBTRACT on a pointer's numeric view handled here (batch lane via pointer_lane()) tests
COMPUTE v = v +/- n on a pointer view (also CICS) handled here tests
POINTER that REDEFINES a BINARY S9(n) (TIOT-INDEX over BUMP-TIOT) handled here program.py, tests
SET ADDRESS OF ... TO ADDRESS OF forms out of scope, still refused translator hole test
second REDEFINES of a pointer view refused by name test
EPSCSMRF SET ADDRESS OF ... TO TOKEN (line 383) now translates; tests in test_det_epscsmrd_holes_5106.py updated 98 pass
Oracle (GnuCOBOL stand-in ggtiot.c) for the walk missing, slice 2 see below
CBSTM03A equivalence case / evidence.py prove missing, slice 3 see below

Sibling gaps

  • Oracle C stand-in laying the same blocks from the same step + equivalence.py lowering: missing; different mechanism (C side, harness); Linux cannot map page 0, 4-byte BINARY view of an 8-byte pointer; source: det: CBSTM03A SET ADDRESS OF over PSA / TCB / TIOT (5 holes; burned CardDemo translation blocker) #5856 checklist [c:80274138].
  • CBSTM03A equivalence case (step from CREASTMT STEP040) and evidence.py prove: missing; needs the oracle first; source: [c:0fb89649].
  • SET ADDRESS OF ... TO ADDRESS OF forms: still refused; no burned program needs them here.

Checklist: done [c:2915c833]
Checklist: partial [c:80274138] -- det side done (CBSTM03A 0 holes); the oracle stand-in is slice 2
Checklist: partial [c:0fb89649] -- equivalence case and evidence.py prove record not yet landed (slice 3)

🤖 Generated with Claude Code

@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Oct 21, 2026
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol marked this pull request as ready for review October 21, 2026 13:18
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol enabled auto-merge (squash) October 21, 2026 13:19
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol

Copy link
Copy Markdown
Owner Author

PR #5868 @ 8012a3c: 2 failed check(s)

== ground-truth part 1/2 (failure) -- real
https://github.com/squid-protocol/gitgalaxy/actions/runs/39606794245/job/119252280360
repro: python -m pytest -q tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_handler_program_s_holes_are_each_owned_by_one_refusal_map_entry
failing tests: tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_handler_program_s_holes_are_each_owned_by_one_refusal_map_entry
errors:
fail-on-cache-miss: false
E AssertionError: ["line 19: CALL CEEMGET: retrieving the message text of an LE condition token is not modelled (the condition token comes from a raised condition, and LE's dispatch of one is missing)"]
tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py:424: AssertionError
FAILED tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_handler_program_s_holes_are_each_owned_by_one_refusal_map_entry - AssertionError: ["line 19: CALL CEEMGET: retrieving the message text of an LE condition token is not mo
##[error]Process completed with exit code 1.
log tail:
env:
GITGALAXY_LICENSE_KEY: COMMUNITY_FREE_TIER
GITGALAXY_MAINFRAME_CORPORA: /home/runner/work/gitgalaxy/gitgalaxy/.mainframe_corpora
MAINFRAME_ENGINE_KEY: 8575d8de95d2c541e7249a0f95ea25ab2ede931a477985528a205fc0b719b90c
PYTHONUTF8: 1
pythonLocation: /opt/hostedtoolcache/Python/3.12.15/x64
PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.12.15/x64/lib/pkgconfig
Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.12.15/x64/lib
##[endgroup]
With the provided path, there will be 1 file uploaded
Artifact name is valid!
Root directory input is valid!
Uploading artifact: test-times-ground-truth-part-1.zip
Beginning upload of artifact content to blob storage
Uploaded bytes 105930
Finished uploading artifact content to blob storage!
SHA256 digest of uploaded artifact is dcf79ced3f24a3935df9f2754d2785d757f640cb85c6ce2904c3f2e7ae0684bd
Finalizing artifact upload
Artifact test-times-ground-truth-part-1 successfully finalized. Artifact ID 12350487473
Artifact test-times-ground-truth-part-1 has been successfully uploaded! Final size is 105930 bytes. Artifact ID is 12350487473
Artifact download URL: https://github.com/squid-protocol/gitgalaxy/actions/runs/39606794245/artifacts/12350487473
Post job cleanup.
[command]/usr/bin/git version
git version 2.55.0
Temporarily overriding HOME='/home/runner/work/_temp/5829c027-d569-45ca-88a0-4f2a4daebf9a' before making global git config changes
Adding repository directory to the temporary git global config as a safe directory
[command]/usr/bin/git config --global --add safe.directory /home/runner/work/gitgalaxy/gitgalaxy/gitgalaxy
Removing SSH command configuration
[command]/usr/bin/git config --local --name-only --get-regexp core.sshCommand
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core.sshCommand' && git config --local --unset-all 'core.sshCommand' || :"
Removing HTTP extra header
[command]/usr/bin/git config --local --name-only --get-regexp http.https://github.com/.extraheader
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http.https://github.com/.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :"
Removing includeIf entries pointing to credentials config files
[command]/usr/bin/git config --local --name-only --get-regexp ^includeIf.gitdir:
[command]/usr/bin/git submodule foreach --recursive git config --local --show-origin --name-only --get-regexp remote.origin.url
Cleaning up orphan processes

== ground-truth part 2/2 (failure) -- real
https://github.com/squid-protocol/gitgalaxy/actions/runs/39606794245/job/119252280382
repro: python -m pytest -q tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_real_epscsmrd_handler_program_holds_pointers_and_two_ceemget_holes_only
failing tests: tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_real_epscsmrd_handler_program_holds_pointers_and_two_ceemget_holes_only
errors:
fail-on-cache-miss: false
E AssertionError: ["line 406: CALL CEEMGET: retrieving the message text of an LE condition token is not modelled (the condition token co...dition token is not modelled (the condition token comes from a raised condition, and LE's dispa
tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py:528: AssertionError
FAILED tests/cobol_mainframe/test_det_epscsmrd_holes_5106.py::test_the_real_epscsmrd_handler_program_holds_pointers_and_two_ceemget_holes_only - AssertionError: ["line 406: CALL CEEMGET: retrieving the message text of an LE condition token
##[error]Process completed with exit code 1.
log tail:
env:
GITGALAXY_LICENSE_KEY: COMMUNITY_FREE_TIER
GITGALAXY_MAINFRAME_CORPORA: /home/runner/work/gitgalaxy/gitgalaxy/.mainframe_corpora
MAINFRAME_ENGINE_KEY: 8575d8de95d2c541e7249a0f95ea25ab2ede931a477985528a205fc0b719b90c
PYTHONUTF8: 1
pythonLocation: /opt/hostedtoolcache/Python/3.12.15/x64
PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.12.15/x64/lib/pkgconfig
Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.15/x64
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.12.15/x64/lib
##[endgroup]
With the provided path, there will be 1 file uploaded
Artifact name is valid!
Root directory input is valid!
Uploading artifact: test-times-ground-truth-part-2.zip
Beginning upload of artifact content to blob storage
Uploaded bytes 105730
Finished uploading artifact content to blob storage!
SHA256 digest of uploaded artifact is ae63e1fcef5f499818ef10d34ebfc2e53bf5d98d86a54670aa42d4f98d0de740
Finalizing artifact upload
Artifact test-times-ground-truth-part-2 successfully finalized. Artifact ID 12350745351
Artifact test-times-ground-truth-part-2 has been successfully uploaded! Final size is 105730 bytes. Artifact ID is 12350745351
Artifact download URL: https://github.com/squid-protocol/gitgalaxy/actions/runs/39606794245/artifacts/12350745351
Post job cleanup.
[command]/usr/bin/git version
git version 2.55.0
Temporarily overriding HOME='/home/runner/work/_temp/b2b8d2cb-44d7-4174-bb45-c6e5df4b0c4a' before making global git config changes
Adding repository directory to the temporary git global config as a safe directory
[command]/usr/bin/git config --global --add safe.directory /home/runner/work/gitgalaxy/gitgalaxy/gitgalaxy
Removing SSH command configuration
[command]/usr/bin/git config --local --name-only --get-regexp core.sshCommand
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core.sshCommand' && git config --local --unset-all 'core.sshCommand' || :"
Removing HTTP extra header
[command]/usr/bin/git config --local --name-only --get-regexp http.https://github.com/.extraheader
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http.https://github.com/.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :"
Removing includeIf entries pointing to credentials config files
[command]/usr/bin/git config --local --name-only --get-regexp ^includeIf.gitdir:
[command]/usr/bin/git submodule foreach --recursive git config --local --show-origin --name-only --get-regexp remote.origin.url
Cleaning up orphan processes

@squid-protocol squid-protocol added the shepherd:needs-fix Bot: a real failure on this head; see the digest comment. Guide: docs/ci.md label Oct 21, 2026
@squid-protocol squid-protocol added shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md and removed shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md labels Oct 21, 2026
@squid-protocol

Copy link
Copy Markdown
Owner Author

CI shepherd: the head of this PR (3b45bb6) is not the one a maintainer labelled shepherd:merge on (new commits, or never approved), so the label was removed and nothing merges unreviewed code. Re-add the label when the new head is ready (shepherd:reapprove marks this PR until then).

@squid-protocol squid-protocol added shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md and removed shepherd:needs-fix Bot: a real failure on this head; see the digest comment. Guide: docs/ci.md shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md labels Oct 21, 2026
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol enabled auto-merge (squash) October 21, 2026 14:01
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

@squid-protocol
squid-protocol merged commit 81ec843 into main Oct 21, 2026
63 checks passed
@squid-protocol
squid-protocol deleted the churn/5856-20261021T1246Z branch October 21, 2026 14:32
@squid-protocol

Copy link
Copy Markdown
Owner Author

No description provided.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant