You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Building a program with -Wsource-uses-openmp -fopenmp -fsycl produces warnings about OpenMP pragmas. Building the same program without -fsycl does not produce any warnings. The source indeed uses OpenMP, but the warning should not be issued as long as we have -fopenmp flag.
To reproduce
#include<iostream>intmain() {
#pragma omp parallel for
for (int i = 0; i < 8; i++) {
std::cout << i << std::endl;
}
return0;
}
$ clang++ simple-sycl-omp.cpp -Wsource-uses-openmp -fopenmp &&echo okok
$ clang++ simple-sycl-omp.cpp -Wsource-uses-openmp -fopenmp -fsyclsimple-sycl-omp.cpp:4:9: warning: unexpected '#pragma omp ...' in program [-Wsource-uses-openmp] 4 | #pragma omp parallel for | ^
Describe the bug
Building a program with
-Wsource-uses-openmp -fopenmp -fsycl
produces warnings about OpenMP pragmas. Building the same program without-fsycl
does not produce any warnings. The source indeed uses OpenMP, but the warning should not be issued as long as we have-fopenmp
flag.To reproduce
Environment
Additional context
The warning comes from the device pass:
The text was updated successfully, but these errors were encountered: