Use greedy rewriter instead of partial conversion in recomposition pass and fuse locations when fusing convolutions
To test the fusing of locations in the recomposition pass, I needed to convert it to a greedy rewriter. The partial conversion did not trigger as the convolutions where not marked as illegal ops.
In my experience the greedy rewriter is general easier to use then applyPartialConversion.
If you prefer it, I could split this PR into multiple for the different commits in it
Hello, the test TestGemmNNPA is failing in the s390x pipeline. I am a bit confused by this, as the code this PR touches, should not affect this test. As I am not familiar with these NNPA tests, it would be great if someone who is more familiar with them could take a quick lock at it
@jenkins-droid test this please
Trying to run the test again just in case it was a fluke.
While working on this, I found out that this parallel-conv optimization pattern misses some precondition checks and sometimes generates an invalid graph/IR due to wrong insertion points. I will update this PR at the beginning of next week to include additional fixes
I updated this PR by including fixes for the following:
- Missing check for static types
- Missing check for no def-use chains between convs
- Wrong insertion point in rewrite, leading to invalid IR
@Arkar-Hema fyi
@jenkins-droid test this please
@AlexandreEichenberger @tungld I added additional fixes for the parallel-conv-fusion in this PR, it would be great if you could review
Jenkins Linux amd64 Build #17035 [push] null... failed after 1 hr 25 min
Jenkins Linux s390x Build #17037 [push] null... failed after 1 hr 37 min
Jenkins Linux ppc64le Build #15981 [push] null... failed after 2 hr 37 min