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

Fixing SYCL build warnings #918

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open
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
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ ENV GTEST_COLOR=1
COPY . /home/umpire/workspace
WORKDIR /home/umpire/workspace/build
RUN /bin/bash -c "source /opt/intel/oneapi/setvars.sh 2>&1 > /dev/null && \
cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_C_COMPILER=icx -DENABLE_WARNINGS_AS_ERRORS=Off -DUMPIRE_ENABLE_DEVELOPER_DEFAULTS=On -DUMPIRE_ENABLE_SYCL=On .. && \
cmake -DCMAKE_CXX_COMPILER=icpx -DCMAKE_C_COMPILER=icx -DCMAKE_CXX_FLAGS=-fsycl -DENABLE_WARNINGS_AS_ERRORS=Off -DUMPIRE_ENABLE_DEVELOPER_DEFAULTS=On -DUMPIRE_ENABLE_SYCL=On .. && \
make -j 16"

FROM ghcr.io/llnl/radiuss:intel-2024.0-ubuntu-20.04 AS intel
Expand Down
2 changes: 1 addition & 1 deletion src/umpire/resource/SyclPinnedMemoryResourceFactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ std::unique_ptr<resource::MemoryResource> SyclPinnedMemoryResourceFactory::creat
}
};

sycl::platform platform(sycl::gpu_selector{});
sycl::platform platform(sycl::gpu_selector_v());

int device_count = 0; // SYCL multi.device count
auto const& devices = platform.get_devices();
Expand Down
6 changes: 3 additions & 3 deletions src/umpire/resource/SyclUnifiedMemoryResourceFactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ std::unique_ptr<resource::MemoryResource> SyclUnifiedMemoryResourceFactory::crea
std::rethrow_exception(e);
} catch (sycl::exception const& ex) {
std::cout << "Caught asynchronous SYCL exception:" << std::endl
<< ex.what() << ", OpenCL code: " << ex.get_cl_code() << std::endl;
<< ex.what() << ", SYCL code: " << ex.code() << std::endl;
}
}
};

sycl::platform platform(sycl::gpu_selector{});
sycl::platform platform(sycl::gpu_selector_v());

int device_count = 0; // SYCL multi.device count
auto const& devices = platform.get_devices();
Expand Down Expand Up @@ -76,7 +76,7 @@ MemoryResourceTraits SyclUnifiedMemoryResourceFactory::getDefaultTraits()
{
MemoryResourceTraits traits;

sycl::device syclDev(sycl::gpu_selector{});
sycl::device syclDev(sycl::gpu_selector_v());
if (syclDev.is_gpu()) {
if (syclDev.get_info<sycl::info::device::partition_max_sub_devices>() > 0) {
auto subDevicesDomainNuma =
Expand Down
Loading