In the pictured situation, CNE will only perform the redirection shown in green:
The red redirection is not performed. Instead, the rightmost loop output becomes a "leader" of its own congruence set.
This should be fixed, and it should ideally also handle cases where the invariant loop variable is not just trivially invariant.
It should also handle the above case even if the order of the two loop variables were switched.
FYI @phate @caleridas
In the pictured situation, CNE will only perform the redirection shown in green:
The red redirection is not performed. Instead, the rightmost loop output becomes a "leader" of its own congruence set.
This should be fixed, and it should ideally also handle cases where the invariant loop variable is not just trivially invariant.
It should also handle the above case even if the order of the two loop variables were switched.
FYI @phate @caleridas