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

Fix CubDebug #430

Merged
merged 1 commit into from
Sep 12, 2023
Merged

Conversation

gevtushenko
Copy link
Collaborator

Description

closes #304

CubDebug is used to report (and reset) CUDA errors. Since CUDA errors are asynchronous, it's possible that the error provided as CubDebug argument is cudaSuccess, but the error returned from cudaGetLastError inside CubDebug is not. Current code organization leads to loosing the error returned from cudaGetLastError. In its turn, this lead to proceeding execution of CUB algorithms instead of returning an error to the user.

This PR fixes CubDebug to return cudaGetLastError result if the input error is not cudaSuccess. This change necessitates fixing most of the CubDebug usages to store the error returned from CubDebug. Without this PR, it's difficult to identify issues that are caused by #166.

Checklist

  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@gevtushenko gevtushenko requested review from a team as code owners September 11, 2023 19:13
@gevtushenko gevtushenko requested review from elstehle and wmaxey and removed request for a team September 11, 2023 19:13
@gevtushenko gevtushenko merged commit a11c1c1 into NVIDIA:main Sep 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

[BUG]: Fix CubDebug
3 participants