Skip to content

fix(pipeline): persist call-site line on CALLS edges#508

Open
alexisperinger-ux wants to merge 2 commits into
DeusData:mainfrom
alexisperinger-ux:fix/persist-call-site-line
Open

fix(pipeline): persist call-site line on CALLS edges#508
alexisperinger-ux wants to merge 2 commits into
DeusData:mainfrom
alexisperinger-ux:fix/persist-call-site-line

Conversation

@alexisperinger-ux

@alexisperinger-ux alexisperinger-ux commented Jun 18, 2026

Copy link
Copy Markdown

Summary

CALLS edges did not carry the source line of the call site, even though CBMCall.start_line is already captured during extraction. This persists it as a line property on CALLS edges in both resolution paths (finalize_and_emit for parallel/registry, a new calls_emit_edge helper for serial/LSP), so call-site lines are queryable (MATCH ()-[r:CALLS]->() RETURN r.line) instead of needing grep.

Fixes #503.

Scope: CALLS only

line is attached to CALLS edges only. Route/config edge props (HTTP_CALLS/ASYNC_CALLS/CONFIGURES) feed the full-only predump passes (create_route_nodes/create_data_flows), which the incremental path does not re-run. Altering those props desyncs full vs incremental indexing (tests/test_incremental.c incr_accuracy_vs_full). Restricting to CALLS keeps those props byte-identical to baseline and preserves full/incremental parity.

Testing

  • Full ASan/UBSan suite (scripts/test.sh): same failure profile as unpatched main (only the pre-existing RSS-ceiling test differs); the previously failing incr_accuracy_vs_full now passes.
  • CALLS edges carry accurate line numbers on both resolution paths; non-CALLS edge props are unchanged.

Changes

  • src/pipeline/pass_parallel.c: finalize_and_emit appends ,"line":N for CALLS.
  • src/pipeline/pass_calls.c: calls_emit_edge helper splices ,"line":N for CALLS and routes the call-edge sites through it.

Persist CBMCall.start_line as a "line" property on CALLS edges in both resolution paths (finalize_and_emit + calls_emit_edge), so call-site lines are queryable instead of needing grep. Scoped to CALLS only: route/config edge props feed full-only predump passes the incremental path does not re-run, so changing them desyncs full vs incremental indexing. Verified: full suite matches unpatched main; line present on CALLS both paths.

Fixes DeusData#503

Signed-off-by: alexisperinger-ux <alexis.peringer@iss-stoxx.com>
Indexes a Go fixture where Helper() is called on line 8 and asserts the Main->Helper CALLS edge persists a line property (line:8) in its JSON props.

Refs DeusData#503.

Signed-off-by: alexisperinger-ux <alexis.peringer@iss-stoxx.com>
@alexisperinger-ux alexisperinger-ux force-pushed the fix/persist-call-site-line branch from d6affbd to fae040d Compare June 19, 2026 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CALLS edges omit the call-site line number (CBMCall.start_line captured but never persisted)

1 participant