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

[STF] Implement a reduce algorithm over CUB #3122

Draft
wants to merge 29 commits into
base: main
Choose a base branch
from

Conversation

caugonnet
Copy link
Contributor

Description

This explores how we can implement C++ algorithms over CUDASTF by the means of CUB, starting from the reduce algorithm

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • [] The documentation is up to date with these changes.

Copy link

copy-pr-bot bot commented Dec 11, 2024

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@caugonnet caugonnet added the stf Sequential Task Flow programming model label Dec 11, 2024
@caugonnet
Copy link
Contributor Author

/ok to test

@caugonnet
Copy link
Contributor Author

/ok to test

@@ -602,7 +602,7 @@ public:
}
}

private:
// private:
Copy link
Collaborator

Choose a reason for hiding this comment

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

😲

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed this is a temporary hack, we need to get rid of that to make the implementation compatible with CUDA graphs anyway.

// This will be the ultimate result of the transform followed by reduce
auto result = ctx.logical_data(shape_of<scalar_view<OutT>>());
// Create a typed task eagerly that we'll use throughout
auto t = ctx.task(result.write(), args.read()...);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Need to move this creation of the task in the inner most lambda

@caugonnet
Copy link
Contributor Author

/ok to test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stf Sequential Task Flow programming model
Projects
Status: In Review
Development

Successfully merging this pull request may close these issues.

3 participants