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

Enable concepts extensions on Clang #1625

Open
kboyarinov opened this issue Feb 3, 2025 · 0 comments
Open

Enable concepts extensions on Clang #1625

kboyarinov opened this issue Feb 3, 2025 · 0 comments
Assignees

Comments

@kboyarinov
Copy link
Contributor

          > > > I think this is a bug in Clang (not only AppleClang): [llvm/llvm-project#61763](https://github.com/llvm/llvm-project/issues/61763)

The bug is fixed in version LLVM 18.1.0.
AppleClang from Xcode 16.2 based on LLVM 17.

I agree that we should just disable these concepts with any Clang for now.
My results of compiling test_blocked_range.cpp on Ubuntu:

  • Clang 14.0.0 - compiles
  • Clang 15.0.0 - compiles
  • Clang 17.0.1 - same compilation error as in MacOS CI above
  • Clang 18.1.0 - compiles
  • Clang 19.1.0 - internal compiler error

Should not we then check the clang's version and enable concepts only if the version is not 17 or not 19? We have __TBB_CLANG_VERSION macro.

I agree, we can enable back concepts on the clang versions not affected by the issue described above.
An other option we have is not to disable concepts completely since the issue only affects TBB classes that uses a constrained friend declaration inside (like blocked_range that friends blocked_range2d.

I still propose to keep concepts on clang totally disabled for this release and create a separate issue for enabling it to make sure other fixes introduced in this patch are landed. I still feel that we need to test the potential fix better on different versions of clang on both Linux and MacOS before enabling concepts.

Originally posted by @kboyarinov in #1611 (comment)

C++20 concepts and TBB APIs constraints are currently disabled on Clang systems due to bug described in the PR above.
We need a stable and tested solution to enable (or partially enable) them on different Clang (Linux and MacOS) systems

@kboyarinov kboyarinov self-assigned this Feb 3, 2025
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

No branches or pull requests

1 participant