Skip to content
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

support bypassing data layout conversion for atomic operator #556

Open
wants to merge 1 commit into
base: triton-mlir
Choose a base branch
from

Conversation

xiaohuguo2023
Copy link
Member

This update is aiming to reduce LDS usage to remove large tile size limitation for stream-k when using atomic_add.

  1. add support for both StoreOp and AtomicRMWOp

and it helps to remove 84

 %83 = arith.truncf %71 : tensor<256x256xf32, #mfma> to tensor<256x256xf16, #mfma>
 %84 = triton_gpu.convert_layout %83 : (tensor<256x256xf16, #mfma>) -> tensor<256x256xf16, #blocked>
          %85 = "tt.atomic_rmw"(%82, %84, %cst_0) <{atomic_rmw_op = 5 : i32, scope = 1 : i32, sem = 4 : i32}> : (tensor<256x256x!tt.ptr<f16, 1>, #blocked>, tensor<256x256xf16, #blocked>, tensor<256x256xi1, #blocked>) -> tensor<256x256xf16, #blocked>

to

 %87 = arith.truncf %75 : tensor<256x256xf32, #mfma> to tensor<256x256xf16, #mfma>
 %88 = "tt.atomic_rmw"(%86, %87, %cst) <{atomic_rmw_op = 5 : i32, scope = 1 : i32, sem = 4 : i32}> : (tensor<256x256x!tt.ptr<f16, 1>, #mfma>, tensor<256x256xf16, #mfma>, tensor<256x256xi1, #mfma>) -> tensor<256x256xf16, #mfma>
        }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant