-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Vectorization][ObjectFifo] Enable larger Matmul + Truncf #856
Conversation
50f009b
to
4f6698f
Compare
8876662
to
bdd6b09
Compare
compiler/plugins/target/AMD-AIE/aievec/VectorToVectorConversions.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/Passes.td
Outdated
Show resolved
Hide resolved
...iler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/test/insert_loops_for_vectorization.mlir
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be at divided into multiple PRs, one containing just the function outlining.
Nice to see this approach working!
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/test/function_outlining.mlir
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice progress! This PR needs a bit more polish. Also please talk with @erwei-xilinx and see if he would help to make AIR tests work with the changes.
compiler/plugins/target/AMD-AIE/aievec/test/precanonicalization-aieml-llvmir.mlir
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEFunctionOutlining.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEFunctionOutlining.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEFunctionOutlining.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Show resolved
Hide resolved
Thanks for the heads up, @yzhang93! WiP on AIR support: #857. |
fd8b5d6
to
c6de3ea
Compare
Thank you so much @erwei-xilinx for the fix! ❤️ I took the changes from Xilinx/mlir-air#752 (created by Erwei) and applied to local I confirm all the tests I commented in this PR works with Erwei's fix. |
c6de3ea
to
0ca6211
Compare
1158090
to
d0c0c34
Compare
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/iree-amd-aie/Transforms/AMDAIEInsertLoopsForVectorization.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
-- This commit makes the following updates to insert-loops-for-vectorization pass. -- It makes it to work on bufferized inputs. -- It also involves update pertaining to collapsing unit dimensions of a candidate generic op. -- Also involves coalescing of the loops generated for tiles. -- This is the first logically grouped PR needed to make Matmul + Truncf work for larger shape, and also unblock other outstanding/dependent PR like #846 Signed-off-by: Abhishek Varma <abhvarma@amd.com>
01017de
to
38d2f48
Compare
compiler/plugins/target/AMD-AIE/aievec/VectorToVectorConversions.cpp
Outdated
Show resolved
Hide resolved
compiler/plugins/target/AMD-AIE/aievec/test/precanonicalization-aieml-llvmir.mlir
Outdated
Show resolved
Hide resolved
@Abhishek-Varma PR looks good other than my small remaining comments. My main concern is that vectorization is being disabled for convolution, hopefully that's not necessary after rebasing? |
Hi @newling - yes, this was an err because of rebasing - I've removed the disabling of vectorization for conv now. |
-- This PR adds the following pieces to enable working of larger Matmul + Truncf.
insert-loops-for-vectorization
to work on bufferized inputs, collapse unit dimensions and coalesce the generated loops for tiling.IREEComprehensiveBufferization
->insert-cores
->insert-loops-for-vectorization
->vectorization
.function-outlining
- which is invoked right afterinsert-cores
pass.aievec
.Signed-off-by: Abhishek Varma abhvarma@amd.com