You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This relates to #1144 which reveals the bug (by making the Hugr fail validation), previously the multiple-edges had been going unnoticed.
The merge_bbs.rs test in_loop with self_loop: true replaces two BBs with one BB that has an edge back to itself. After performing the Replacement, the new BB in the Hugr has four edges back to itself (all from the same port).
I've checked the Replacement - the replacement Hugr contains exactly one self-edge, mu_out contains exactly one edge leaving the replacement, mu_inp is empty - all as expected.
The problem appears to arise immediately after this:
i.e. before we even inspect mu_inp / mu_out etc. So I believe this is due to CQCL/portgraph#130 but I'm not clear why we see four copies of the edge as from that portgraph issue I would expect to see two.
The text was updated successfully, but these errors were encountered:
…1144)
This was missed in prior validation, and there are a few instances in
our codebase, so fix them.
I also had to comment out a failing merge_bbs test, see #1143
BREAKING CHANGE: BasicBlocks with multiple successors from the same
outport will now fail to validate (as they should!)
This relates to #1144 which reveals the bug (by making the Hugr fail validation), previously the multiple-edges had been going unnoticed.
The
merge_bbs.rs
testin_loop
withself_loop: true
replaces two BBs with one BB that has an edge back to itself. After performing the Replacement, the new BB in the Hugr has four edges back to itself (all from the same port).I've checked the
Replacement
- thereplacement
Hugr contains exactly one self-edge,mu_out
contains exactly one edge leaving thereplacement
,mu_inp
is empty - all as expected.The problem appears to arise immediately after this:
hugr/hugr-core/src/hugr/rewrite/replace.rs
Line 282 in 1032b7a
i.e. before we even inspect
mu_inp
/mu_out
etc. So I believe this is due to CQCL/portgraph#130 but I'm not clear why we see four copies of the edge as from that portgraph issue I would expect to see two.The text was updated successfully, but these errors were encountered: