Han-Chung Wang

Results 336 comments of Han-Chung Wang

Adding a working IR that uses the memref directly, and it works: https://gist.github.com/hanhanW/4314bd77cb24468b3ebdea2cb9d274f5 The naming of variables looks confusing, because I made the change by hands. It is easier to...

I got a smaller repro, and I trimed down IREE specifics. To repro: `iree-opt --iree-transform-dialect-interpreter --allow-unregistered-dialect repro.mlir` ```mlir func.func @hoist_vector_transfer_pairs( %memref0: memref

I think the issue is about how we implement MemoryEffectOpInterface for the memref.assume_alignment op. I'll take a look later. Upstream implementation for hoisting: https://github.com/llvm/llvm-project/blob/main/mlir/lib/Dialect/Linalg/Transforms/Hoisting.cpp

I verified that https://github.com/llvm/llvm-project/pull/144809 can fix the issue, see https://github.com/iree-org/iree/pull/21133.

Do you only want to generalize it when it is a transposition? How about other cases? We have a [DecomposePackUnPackOpsPass](https://github.com/iree-org/iree/blob/main/compiler/src/iree/compiler/Codegen/Common/DecomposePackUnPackOps.cpp), which converts pack ops to pad + reshape + transpose...

okay, I just figured out what we want to do and a better way to approach it. I was confused that why there are no reshapes generated in the pattern,...

> I think the problem with not having the reshape is that it only works for `flow.dispatch.tensor.store` consumers as the type gets changed and other consumer ops will give an...

I think it is better to close the issue when we truly address it in IREE. E.g., remove the `war` flags from the codebase.

I think you can play with the actual commands/files. Please take a look at https://iree.dev/guides/ml-frameworks/onnx/

Did you try `canonicalize,cse,canonicalize` after bufferization? I remember there are issues to eliminate the allocation. The workaround is running these three passes after bufferization. https://github.com/iree-org/iree/blob/0f15c8df0e8f61ecb5e5755a5df00a535648a5f9/compiler/src/iree/compiler/Codegen/Common/IREEComprehensiveBufferizePass.cpp#L249-L254