[BUG] Disordered header files: detail::is_prefetch used before declaration.
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 10.5k
- Forks
- 2.1k
- Avg merge
- 3d 11h
- Merged PRs (30d)
- 7
Description
Describe the bug
Disordered header files (use before declaration) in latest CUTLASS version.
If cute/algorithm/prefetch.hpp was included, eventually it will include cutlass/include/cute/arch/copy_sm90_tma.hpp.
This included file uses detail::is_prefetch<CopyOp> while detail::is_prefetch is defined in cute/algorithm/prefetch.hpp but not included yet.
Including link:
cute/algorithm/prefetch.hpp
-> cute/tensor.hpp
-> cute/algorithm/copy.hpp
-> cutlass/include/cute/atom/copy_atom.hpp
-> cutlass/include/cute/atom/copy_traits_sm90_tma.hpp
Steps/Code to reproduce bug
Add
#include "cute/algorithm/prefetch.hpp"
to any example file.
For example, in 57_hopper_grouped_gemm:
Expected behavior
Compilation error occurs:
Environment details (please complete the following information):
- CUTLASS: 7d49e6c7e2f8896c47f586706e67e1fb215529dc
- CUDA 12.4
- GCC 11.4
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the include chain from cute/algorithm/prefetch.hpp through cute/tensor.hpp, cute/algorithm/copy.hpp, and the listed atom headers, then inspect the use in copy_sm90_tma.hpp against the declaration in prefetch.hpp. Reproduce by adding the include to 57_hopper_grouped_gemm; done means the example compiles without the declaration error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100