Repository navigation
Mainframe fact channel: batch CALL USING contracts (#3454) - #3475
Merged
Merged
Conversation
Contributor
#3355 matched CICS COMMAREAs to the callee's DFHCOMMAREA; a batch `CALL 'X' USING A B C` passes its data positionally to the callee's `PROCEDURE DIVISION USING P Q R`, and neither side was recorded, so an arity or length mismatch was invisible. core/call_using.py: - a CALL's USING list, by position (BY CONTENT / BY VALUE prefix the items that follow, `A OF B` kept, subscripts dropped, ADDRESS OF / LENGTH OF / OMITTED / literals as written), ending at RETURNING / ON / NOT / END-CALL / a period / the next verb -> call_site_data.using_args (a column, like #3355's COMMAREA; healed onto older tables; only on a CALL that has one, so every other row keeps its shape); - each PROCEDURE DIVISION [USING] and ENTRY 'X' [USING] -> entry_point_data. Sequence fields are blanked once per file (a slice would misplace cols 73-80). galaxy_ir: EngineCall.using_args, EngineEntryPoint / EngineFile.entry_points, and GalaxyIR.call_contracts(): each CALL paired with its callee's entry (the ENTRY the target names, else the PROCEDURE DIVISION) -- status paired / arity_mismatch / callee_unresolved / callee_no_using / caller_no_using -- and per position the argument's and parameter's byte length (record_layout, COPY-expanded) and length_match. CardDemo: CBSTM03A -> CBSTM03B (13 sites, 1040 = 1040 bytes), CORPT00C / COTRN02C -> CSUTLDTC (10/10/80 = 10/10/80); the other 43 CALLs go to LE / MQ services outside the repo. zopeneditor: SAM1 -> SAM2 (4 and 5 arguments). Ground truth: an independent reader (add-call-using) and a scored field "CALL USING" (drafted). Engine matches the key exactly: CardDemo 71/71, CBSA 22/22, zopeneditor 5/5. Golden masters: a USING field on 227 call sites (purely additive) and new Entry Points blocks. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g
…#3478) IMS database calls were invisible: nothing said which programs read or update which IMS segments. core/dli_calls.py: one row per EXEC DLI command (the command, PCB(...), each SEGMENT(...) of a path call, INTO / FROM, WHERE(...), SCHD PSB((name))) and per CALL 'CBLTDLI' / 'AIBTDLI' (function operand, PCB mask, I/O area, SSAs -- read with the #3454 USING reader), operands as written -> dli_call_data. galaxy_ir: EngineDliCall / EngineFile.dli_calls and - ims_calls(): a CBLTDLI function code resolved through its data item's VALUE (FUNC-GU lives in a copybook) and each SSA decoded from its group's COPY-expanded VALUEs -- segment name, `(FIELD OP` qualification or `*` command codes; EXEC WHERE clauses paired with their segments; - ims_segment_access(): the program x segment matrix (the IMS counterpart of sql_table_access). A path call acts on its last segment and reads the parents it positions through. CardDemo: 35 calls over PAUTSUM0 / PAUTDTL1 in 7 programs -- e.g. COPAUA0C reads / updates / inserts PAUTSUM0 and inserts PAUTDTL1 under it; CBPAUP0C reads and deletes both; DBUNLDGS reads both and ISRTs its GSAM PCBs (no SSA). Ground truth: an independent reader (add-dli) with its own copybook lookup and PIC-width VALUE decoding, and two scored fields, "DL/I calls" and "IMS segment access" (drafted). Engine matches the key exactly: CardDemo 35/35 calls and 20/20 segment accesses (no IMS in CBSA or zopeneditor). Golden masters unchanged (no IMS in the crucible corpus). PSB / DBD generation sources are not scanned yet; follow-up issue. Claude-Session: https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g Co-authored-by: Claude Opus 5.5 <[email protected]>
squid-protocol
force-pushed
the
feat/call-using-3454
branch
from
September 24, 2026 12:54
efb0328 to
74d5a2c
Compare
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3454. Part of #3445. Stacked on #3474; GitHub retargets it to
mainwhen #3474 merges.#3355 matched CICS COMMAREAs to the callee's DFHCOMMAREA. A batch
CALL 'X' USING A B Cpasses its data positionally to the callee'sPROCEDURE DIVISION USING P Q R, and neither side was recorded, so an arity or length mismatch was invisible.What
core/call_using.py:call_site_data.using_args.A OF Bis kept; subscripts are dropped; ADDRESS OF, LENGTH OF, OMITTED and literals are kept as written.PROCEDURE DIVISION [USING]andENTRY 'X' [USING]→entry_point_data.GalaxyIR.call_contracts()pairs each CALL with its callee's entry point: the ENTRY the target names, otherwise the PROCEDURE DIVISION.status: paired, arity_mismatch, callee_unresolved, callee_no_using, or caller_no_using.record_layout, COPY-expanded) andlength_match.Corpora
Ground truth
add-call-using.CALL USING, drafted.Checks
USINGfield on 227 call sites (verified purely additive: nothing removed or changed), plus newEntry Pointsblocks.🤖 Generated with Claude Code
https://claude.ai/code/session_017ZsVaAkb86P5r5JXDC2Y9g