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

[Tests] Improve tests about warning-free SYCL headers #15081

Open
AlexeySachkov opened this issue Aug 14, 2024 · 0 comments
Open

[Tests] Improve tests about warning-free SYCL headers #15081

AlexeySachkov opened this issue Aug 14, 2024 · 0 comments
Labels
confirmed enhancement New feature or request good first issue Good for newcomers

Comments

@AlexeySachkov
Copy link
Contributor

Is your feature request related to a problem? Please describe

This is prompted by discussion we had in #15064: we already have some testing to check that SYCL headers are warning-free, but it can always be improved. In particular, we allow to use a 3rd party compiler to build host part of SYCL applications and in that phase/mode SYCL headers are not considered to be system headers, so any warnings coming out of them may break -Werror builds or just annoy users polluting their build logs.

Describe the solution you would like

As a first step, we should copy existing warnings.cpp test and compile it using gcc instead of clang++:

// RUN: %clangxx -fsycl --no-system-header-prefix=sycl -fsyntax-only -Wall -Wextra -Werror -Wno-ignored-attributes -Wno-deprecated-declarations -Wpessimizing-move -Wmismatched-tags -Wno-unknown-cuda-version -Wno-unused-command-line-argument %s
// RUN: %clangxx -fsycl -E --no-system-header-prefix=sycl %s -o %t.ii
// RUN: %clangxx -fsycl -fsyntax-only -Wall -Wextra -Werror -Wno-ignored-attributes -Wno-deprecated-declarations -Wpessimizing-move -Wmismatched-tags -Wno-unknown-cuda-version -Wno-unused-command-line-argument %t.ii

Going forward, this (and existing) tests could be further expanded, but having a test with gcc would be already a good start.

Describe alternatives you have considered

No response

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant