Repository navigation
Engine record layouts: POINTER width as a parameter, shared stand-in copybooks (Part of #5649) - #5656
Conversation
…ecord_layout Co-Authored-By: Claude Opus 5.5 <[email protected]>
…flows 4945 -> 4953 The engine side of `offsets` now lays out at the translator's POINTER width and reads the same stand-in copybooks: 380 translator-uses-mq-stand-ins, 204 offsets pointer-width and 2 translator-uses-stand-in-copybook entries no longer reproduce. Eight COPAUA0C MOVEs into MQ fields now resolve. The #5649 record_layout tests move into test_fact_crosscheck.py. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…s gate) Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
No description provided. |
|
PR #5656 @ fdf2f4c: 1 failed check(s) == full-suite part 2/3 (failure) -- real |
|
CI shepherd: the head of this PR (41e7e4f) is not the one a maintainer labelled |
|
No description provided. |
|
No description provided. |
Part of #5649. Slice 1 = the issue's Work steps 1-2.
Owner decisions
Issue #5649 (owner OK 2026-10-19): translator consumes engine record layouts.
What changes
GalaxyIR.record_layout(..., pointer_bytes=None)threads the width through_elementary_bytes,_sync_boundaryand_slack. The default isZOS_POINTER_BYTES = 4(IBM Enterprise COBOL under LP(32): 4 bytes, fullword-aligned under SYNC). Every caller that doesn't pass the parameter (COMMAREA contracts, thelayoutschannel, referees) keeps z/OS 4, so no engine output moves. Under SYNC a POINTER aligns on its own width.core/copy_libraries.pygainsSTAND_IN_DIR(the det translator'sdet/copy, the same filesdet/source._SHIPPED_COPYfalls back on),stand_in_registers()(CMQ* -> register W1 viamq.STAND_INS, CEEIGZCT -> L4) andstand_in_text(), which blanks comments and the sequence area.load_galaxy_irattaches a parsed stand-in (stand-in#MEMBER) to each COBOL file that COPYs a registered member the repository does not hold. It sits on a newEngineFile.stand_in_copies, which only_copybook_filereads, after real copybooks and BMS symbolic maps. A repository copybook always wins.record_layoutaddsstand_ins: [...]only when the layout read one, so other layouts keep their shape.engine_extraslays the engine side ofoffsetsout at the translator's storage width (det.cics.POINTER_BYTES, 8: GnuCOBOL x86-64, register C9).Class sweep
Class: the engine and the translator lay out the same record from different inputs: a platform setting (POINTER width) and system copybooks only one side could read.
offsets)offsets)FC(2offsets)Sibling gaps
_elementary_bytesreturns None). IBM: PROCEDURE-POINTER is 8 bytes, FUNCTION-POINTER is a pointer. Needed by DBB MortgageApplicationepscsmrd.cbl(1 ROUTINE PROCEDURE-POINTER, 3 records). Not in the ledger today: the cross-check only lays out records the translator lays out.POINTER SYNC(grep of the burned corpora), so there is nothing to prove there yet.det/copydirectory, but they are not register stand-ins. The engine treats them as system members (unexpanded). Programs that would need them: CardDemo COCRDUPC, COUSR01C, COTRN02C (DFHAID); CBSA UPDACC. Nooffsetsentry today: those are separate 01s the cross-check records do not reach.data_flowsspan resolved through a stand-in carries no stand-in flag. The 8 newly resolved CardDemo COPAUA0C MOVEs (intoMQOD-OBJECTNAME OF MQM-OD-REQUEST,MQMD-CORRELID OF MQM-MD-REQUEST…) point at stand-in storage without saying so. Onlyrecord_layoutflags it.layoutschannel, CBSAPROCISRT.cpy(6pointer-widthentries) stays. That channel scores against the keys and referees, which are z/OS (4), so it is definitional and correct to keep.Remaining slices
docs/language_status/fact_ownership.mdand add an "After Translator consumes engine record layouts (fact_ownership.md follow-up): POINTER width as a parameter, shared stand-in copybooks, retire the duplicate layout computation #5649" paragraph with the numbers below.Gates and evidence
fact_crosscheck.py update, unscoped). By cause:translator-uses-mq-stand-ins380 -> 0,pointer-width210 -> 6 (thelayoutsentries above),translator-uses-stand-in-copybook2 -> 0. No new entry. Both causes that no longer have entries leavecauses.data flows4945 -> 4953 (of 5054). These are the 8 COPAUA0C MOVEs into MQ fields that now resolve. I diffed the flows one by one with and without stand-ins: 8 unresolved -> resolved, nothing else moved.pr_gates.py --fast: 6/6 pass.pr_gates.py --ratchets: 8/8 pass (after the ledger update and pin).audit_check.py: all clear. Tree-wide guard tests: pass.time_ratchet.py check: 0 over the limit.tests/cobol_mainframe/test_fact_crosscheck.pyadds a toy-repo scan covering:Lessons for agents
tests/test_source_reads.py(rule 2) flags a text-moderead_text()in anygitgalaxy/core/module, even when it reads GitGalaxy's own shipped file (here, a stand-in copybook). Read throughgitgalaxy.core.source_text.read_source.record_layout:_copybook_filealso feeds_find_item, sodata_flowsand thecompletenesspins intest_completeness.pymove too. Runpr_gates --ratchetsafter the change and diff the moved flows one by one.🤖 Generated with Claude Code