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] CUTE SGEMM Example Doesn't Compile #1854

Closed
abhishekvijeev opened this issue Oct 8, 2024 · 6 comments
Closed

[BUG] CUTE SGEMM Example Doesn't Compile #1854

abhishekvijeev opened this issue Oct 8, 2024 · 6 comments
Labels
? - Needs Triage bug Something isn't working

Comments

@abhishekvijeev
Copy link

Hi,

The CUTE example in examples/cute/tutorial/sgemm_1.cu doesn't compile. I receive the following error:

src/main.cu(104): error: identifier "X" is undefined
    Tensor gA = local_tile(mA, cta_tiler, cta_coord, Step<_1, X,_1>{});
                                                              ^

./cutlass/include/cute/container/tuple.hpp(175): error: incomplete type is not allowed
  struct tuple : detail::TupleBase<make_index_sequence<sizeof...(T)>, T...>
                 ^
          detected during instantiation of class "cute::tuple<T...> [with T=<cute::_1, <error-type>, cute::_1>]" at line 104 of src/main.cu

src/main.cu(105): error: identifier "X" is undefined
    Tensor gB = local_tile(mB, cta_tiler, cta_coord, Step< X,_1,_1>{});
                                                           ^

./cutlass/include/cute/container/tuple.hpp(175): error: incomplete type is not allowed
  struct tuple : detail::TupleBase<make_index_sequence<sizeof...(T)>, T...>
                 ^
          detected during instantiation of class "cute::tuple<T...> [with T=<<error-type>, cute::_1, cute::_1>]" at line 105 of src/main.cu

src/main.cu(106): error: identifier "X" is undefined
    Tensor gC = local_tile(mC, cta_tiler, cta_coord, Step<_1,_1, X>{});
                                                                 ^

./cutlass/include/cute/container/tuple.hpp(175): error: incomplete type is not allowed
  struct tuple : detail::TupleBase<make_index_sequence<sizeof...(T)>, T...>
                 ^
          detected during instantiation of class "cute::tuple<T...> [with T=<cute::_1, cute::_1, <error-type>>]" at line 106 of src/main.cu

src/main.cu(138): error: identifier "X" is undefined
    Tensor tCsA = local_partition(sA, tC, threadIdx.x, Step<_1, X>{});
                                                                ^

./cutlass/include/cute/container/tuple.hpp(175): error: incomplete type is not allowed
  struct tuple : detail::TupleBase<make_index_sequence<sizeof...(T)>, T...>
                 ^
          detected during instantiation of class "cute::tuple<T...> [with T=<cute::_1, <error-type>>]" at line 138 of src/main.cu

src/main.cu(140): error: identifier "X" is undefined
    Tensor tCsB = local_partition(sB, tC, threadIdx.x, Step< X,_1>{});
                                                             ^

./cutlass/include/cute/container/tuple.hpp(175): error: incomplete type is not allowed
  struct tuple : detail::TupleBase<make_index_sequence<sizeof...(T)>, T...>
                 ^
          detected during instantiation of class "cute::tuple<T...> [with T=<<error-type>, cute::_1>]" at line 140 of src/main.cu

Has CUTE's API changed such that the placeholder X no longer works?

Thanks!

@abhishekvijeev abhishekvijeev added ? - Needs Triage bug Something isn't working labels Oct 8, 2024
@thakkarV
Copy link
Collaborator

thakkarV commented Oct 8, 2024

Can you please include your version and toolchain info and repro steps?

@abhishekvijeev
Copy link
Author

Sure. I'm using the main branch of CUTLASS and have created a repo with instructions to reproduce the issue:

https://github.com/abhishekvijeev/cute_gemm_test/tree/main

Here's the output of nvcc --version:

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2024 NVIDIA Corporation
Built on Fri_Jun_14_16:34:21_PDT_2024
Cuda compilation tools, release 12.6, V12.6.20
Build cuda_12.6.r12.6/compiler.34431801_0

Please let me know if any additional information is needed.

Thanks!

@thakkarV
Copy link
Collaborator

thakkarV commented Oct 8, 2024

Your cmake setup is incorrect. You need to add the cutlass dir as a subdir in your cmake config

@abhishekvijeev
Copy link
Author

Ah I see, thank you!

@abhishekvijeev
Copy link
Author

Hi,

I added the cutlass directory as a subdirectory using add_subdirectory(./cutlass) - that doesn't seem to fix the issue. Did you mean something else?

Thanks!

@abhishekvijeev
Copy link
Author

Oddly enough, using Underscore instead of X works fine!

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

2 participants