Skip to content

[tmva][sofie] Reset operator-fusion state for each parsed graph - #23230

Merged
guitargeek merged 1 commit into
root-project:masterfrom
guitargeek:sofie-parser-fusion-state
Sep 3, 2026
Merged

[tmva][sofie] Reset operator-fusion state for each parsed graph#23230
guitargeek merged 1 commit into
root-project:masterfrom
guitargeek:sofie-parser-fusion-state

Conversation

@guitargeek

Copy link
Copy Markdown
Contributor

RModelParser_ONNX::fFusedOperators records operator-fusion decisions (e.g. Gemm+Relu) keyed by node index, but was never cleared. Reusing one parser instance for a second model replayed the stale fusion decisions of the first model against unrelated nodes, leading to wrong models or crashes (e.g. a segfault in ParseFuseGemmRelu when the stale index points to a zero-input Constant node).

The map is also per-graph state: ParseONNXGraph is called recursively for the subgraphs of the If operator, whose node indices would collide with those of the enclosing graph.

🤖 Done with the help of AI

RModelParser_ONNX::fFusedOperators records operator-fusion decisions
(e.g. Gemm+Relu) keyed by node index, but was never cleared.  Reusing
one parser instance for a second model replayed the stale fusion
decisions of the first model against unrelated nodes, leading to wrong
models or crashes (e.g. a segfault in ParseFuseGemmRelu when the stale
index points to a zero-input Constant node).

The map is also per-graph state: ParseONNXGraph is called recursively
for the subgraphs of the If operator, whose node indices would collide
with those of the enclosing graph.

🤖 Done with the help of AI
@github-actions

github-actions Bot commented Sep 2, 2026

Copy link
Copy Markdown

Test Results

    22 files      22 suites   3d 12h 5m 29s ⏱️
 3 864 tests  3 864 ✅ 0 💤 0 ❌
74 927 runs  74 927 ✅ 0 💤 0 ❌

Results for commit 4a6845b.

@lmoneta lmoneta left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@guitargeek
guitargeek merged commit 74baa35 into root-project:master Sep 3, 2026
41 of 42 checks passed
@guitargeek
guitargeek deleted the sofie-parser-fusion-state branch September 3, 2026 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants