Skip to content

[SYCL] Silence warnings for #warning directive in CL/sycl.hpp #13602

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

Merged
merged 2 commits into from
Apr 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions sycl/include/CL/sycl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
#pragma once

#if defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wpedantic"
#warning "CL/sycl.hpp is deprecated, use sycl/sycl.hpp"
#pragma clang diagnostic pop
#endif

#include <sycl/sycl.hpp>
Expand Down
2 changes: 1 addition & 1 deletion sycl/test/warnings/sycl_2020_deprecations.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// RUN: %clangxx %fsycl-host-only -fsyntax-only -ferror-limit=0 -sycl-std=2020 -Xclang -verify -Xclang -verify-ignore-unexpected=note %s

// expected-warning@sycl/CL/sycl.hpp:12 {{CL/sycl.hpp is deprecated, use sycl/sycl.hpp}}
// expected-warning@sycl/CL/sycl.hpp:* {{CL/sycl.hpp is deprecated, use sycl/sycl.hpp}}
#include <CL/sycl.hpp>
#include <sycl/ext/intel/experimental/online_compiler.hpp>

Expand Down
2 changes: 1 addition & 1 deletion sycl/unittests/SYCL2020/AtomicFenceCapabilities.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
//===----------------------------------------------------------------------===//

#include <CL/sycl.hpp>
#include <sycl/sycl.hpp>
#include <gtest/gtest.h>
#include <helpers/PiMock.hpp>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
//===----------------------------------------------------------------------===//

#include <CL/sycl.hpp>
#include <sycl/sycl.hpp>
#include <gtest/gtest.h>
#include <helpers/PiMock.hpp>

Expand Down
2 changes: 1 addition & 1 deletion sycl/unittests/queue/DeviceCheck.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
//===----------------------------------------------------------------------===//

#include <CL/sycl.hpp>
#include <sycl/sycl.hpp>
#include <detail/config.hpp>
#include <detail/device_impl.hpp>
#include <gtest/gtest.h>
Expand Down