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

Upgrade metal 516a8917fac17649abbc9052b680894b432b4de6 #456

Merged
merged 1 commit into from
Aug 29, 2024

Conversation

nsmithtt
Copy link
Contributor

@nsmithtt nsmithtt commented Aug 21, 2024

@nsmithtt
Copy link
Contributor Author

@pjanevskiTT, with this upgrade we now are tracking metal main

@pjanevskiTT
Copy link
Contributor

pjanevskiTT commented Aug 21, 2024

This looks great, thanks Nick. Few things I wanted to ask/mention

  • When I want to build standalone metal inside tt-mlir, I need to set ENABLE_LIBCXX to OFF in order to use libstd. Is there some smart way to do this? Only way I found is basically doing set(ENABLE_LIBCXX OFF) inside CMakeLists.txt in tt-metal repo.
  • Even when I force ENABLE_LIBCXX to off, build fails. Required change to make the build work is changing this line to
    using type = std::nullptr_t;

It looks like metal builds with this change as well, so maybe we can change it in order to support building it inside tt-mlir as well. If it makes sense, I can make the change on tt-metal side

Otherwise, this PR looks great. I think development and integration is going to be very smooth this way, thanks once again

@nsmithtt
Copy link
Contributor Author

This looks great, thanks Nick. Few things I wanted to ask/mention

  • When I want to build standalone metal inside tt-mlir, I need to set ENABLE_LIBCXX to OFF in order to use libstd. Is there some smart way to do this? Only way I found is basically doing set(ENABLE_LIBCXX OFF) inside CMakeLists.txt in tt-metal repo.

When you invoke cmake from the cmake command line you can do -DENABLE_LIBCXX=OFF.

  • Even when I force ENABLE_LIBCXX to off, build fails. Required change to make the build work is changing this line to
    using type = std::nullptr_t;

Hmm, this feels like a compiler version issue. Our CI is able to build with it disabled, I think we are using clang-17 though. If there is a simple fix on the metal side to support your compiler version I'd go ahead and create a PR against metal with commit message #0: Build error supports clang-.....

It looks like metal builds with this change as well, so maybe we can change it in order to support building it inside tt-mlir as well. If it makes sense, I can make the change on tt-metal side

Yes so metal builds with this change, left default enabled. But if you look at this PR, we set -DENABLE_LIBCXX=OFF.

@@ -47,8 +48,9 @@ ExternalProject_Add(
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
-DCMAKE_CXX_COMPILER_LAUNCHER=${CMAKE_CXX_COMPILER_LAUNCHER}
-DENABLE_TRACY=${TT_RUNTIME_ENABLE_PERF_TRACE}
-DENABLE_LIBCXX=OFF
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pilkicTT
Copy link
Contributor

@nsmithtt can you confirm if everything works on silicon? I've been trying something out on forge side (on this branch of mlir), and am hitting some issues when creating sys desc (n300 machine)... concretely, when deviceMesh.close_devices() is called in getCurrentSystemDesc(), everything hangs...

@nsmithtt
Copy link
Contributor Author

@nsmithtt can you confirm if everything works on silicon? I've been trying something out on forge side (on this branch of mlir), and am hitting some issues when creating sys desc (n300 machine)... concretely, when deviceMesh.close_devices() is called in getCurrentSystemDesc(), everything hangs...

Hmm, so mine isn't hanging, but the simple_sum test does error out with OOM. I'm going to hold off on merging this until we have silicon CI in place which I think is close to landing. I don't want to destabilize.

@nsmithtt nsmithtt force-pushed the nsmith/upgrade-metal2 branch from bccca5d to 5768439 Compare August 28, 2024 21:56
@nsmithtt nsmithtt requested a review from tapspatel as a code owner August 28, 2024 21:56
@nsmithtt
Copy link
Contributor Author

FYI all, going to try and uplift now that we have silicon CI.

@nsmithtt nsmithtt changed the title Upgrade metal 5cf3d9544cd36078e19b556a91cc39b87236a4f0 Upgrade metal 516a8917fac17649abbc9052b680894b432b4de6 Aug 28, 2024
@nsmithtt nsmithtt merged commit 250bc00 into main Aug 29, 2024
13 checks passed
@nsmithtt nsmithtt deleted the nsmith/upgrade-metal2 branch August 29, 2024 01:28
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.

4 participants