Skip to content

Replace internal assert with _CCCL_ASSERT in libcu++#6825

Merged
davebayer merged 1 commit intoNVIDIA:mainfrom
davebayer:replace_assert
Dec 2, 2025
Merged

Replace internal assert with _CCCL_ASSERT in libcu++#6825
davebayer merged 1 commit intoNVIDIA:mainfrom
davebayer:replace_assert

Conversation

@davebayer
Copy link
Contributor

No description provided.

@davebayer davebayer requested a review from a team as a code owner December 1, 2025 19:24
@github-project-automation github-project-automation bot moved this to Todo in CCCL Dec 1, 2025
@cccl-authenticator-app cccl-authenticator-app bot moved this from Todo to In Review in CCCL Dec 1, 2025
case __ATOMIC_ACQ_REL: [[fallthrough]];
case __ATOMIC_RELEASE: __cuda_atomic_fence(_Sco{}, __atomic_cuda_acq_rel{}); break;
case __ATOMIC_RELAXED: break;
default: assert(0);
Copy link
Contributor

Choose a reason for hiding this comment

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

assert(0) sounds like the path is never reached rather than a real assertion. Anyway, that's fine for this PR

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Would you prefer _CCCL_UNREACHABLE() in this case?

Copy link
Contributor

Choose a reason for hiding this comment

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

_CCCL_UNREACHABLE should be the right solution but it doesn't provide any debug info. I already tried to improve it but I didn't want to spent time on this #4460

@davebayer davebayer enabled auto-merge (squash) December 1, 2025 20:08
@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

github-actions bot commented Dec 2, 2025

🥳 CI Workflow Results

🟩 Finished in 1h 17m: Pass: 100%/90 | Total: 1d 06h | Max: 1h 17m | Hits: 91%/214635

See results here.

@davebayer davebayer merged commit a5df4b1 into NVIDIA:main Dec 2, 2025
101 of 102 checks passed
@github-project-automation github-project-automation bot moved this from In Review to Done in CCCL Dec 2, 2025
@davebayer davebayer self-assigned this Dec 3, 2025
@davebayer davebayer deleted the replace_assert branch January 9, 2026 09:02
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.

2 participants