Closed AlexandreEichenberger closed 3 years ago
It seems that you are using unrollAndJam in MLIR which does know about krnl.load and krnl.store. So during the lowering where krnl.load and krnl.store have not lowered to affine.load and affine.store, they become illegal to unrollAndJam. This likely depends on the order of evaluation.
@tungld , we found a way to make it work... will push the solution soon
I created a custom branch to evaluate what is happening in the unroll and jam. #769
The original onnx program
can be lowered to affine with
and when the
#define UNROLL_IT 1
is set to 1, I get the crash below.I added code to dump the function before returning success from the lower matmul pattern. The code is below. I just commented out the matmul operation that was replaced by the other code. Its a mixture of affine and krnl.load/store
At a cursory glance, the code looks ok. I did feed it back to
onnx-mlir-opt
asking again to lower krnl to affine and it results in a code below. Without any crashes.I don't know at this time how to debug it.