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

[BUG] Wrong default reduction_identity on Epilogue Reduction Store operations #2105

Open
bdh0404 opened this issue Feb 13, 2025 · 2 comments
Labels
? - Needs Triage bug Something isn't working

Comments

@bdh0404
Copy link

bdh0404 commented Feb 13, 2025

Describe the bug
For my custom EVT computation, I used a Sm90RowReduction class with half-precision floating point addition reduction, with the default reduction identity as ElementCompute(0.0f) where the ElementCompute is cutlass::half_t as argument input. However, a compile error occurred due to the incorrectly stated default value of reduction_identity.

Steps/Code to reproduce bug

/home/user/workspace/cutlass/include/cutlass/epilogue/fusion/sm90_visitor_store_tma_warpspecialized.hpp(683): error: no suitable constructor exists to convert from "int" to "cutlass::half_t"
ElementCompute reduction_identity = 0;

Where the ElementCompute is cutlass::half_t.

The EVT I used for is
cutlass::epilogue::fusion::Sm90EVT<
cutlass::epilogue::fusion::Sm90RowReduction<cutlass::plus, cutlass::plus, cutlass::plus, 0, TileShape, ElementCompute, ElementCompute,
RoundStyle>,
...>
Which accumulates epilogue results row-wise with half-precision floating-point addition.

This compile bug happens due to an incorrectly stated default value of reduction_identity.

Expected behavior

No compile error.

Environment details (please complete the following information):

  • Docker Nvidia CUDA 12.6.3 image

Additional context

Changing the default values of reduction_identity variables of those reduction classes from "0" to "ElementCompute(0)" eliminates the compile error.

@bdh0404 bdh0404 added ? - Needs Triage bug Something isn't working labels Feb 13, 2025
@thakkarV
Copy link
Collaborator

thanks for the bug report!

@hwu36
Copy link
Collaborator

hwu36 commented Feb 19, 2025

@Junkai-Wu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
? - Needs Triage bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants