Skip to content
Draft
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 sycl/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ option(SYCL_ENABLE_WERROR "Treat all warnings as errors in SYCL project" OFF)
option(SYCL_DISABLE_STL_ASSERTIONS "Disable assertions in STL containers" ON)
option(SYCL_ADD_DEV_VERSION_POSTFIX "Adds -V postfix to version string" ON)
option(SYCL_ENABLE_COVERAGE "Enables code coverage for runtime and unit tests" OFF)
option(SYCL_ENABLE_STACK_PRINTING "Enables stack printing on crashes of SYCL applications" OFF)
option(SYCL_ENABLE_STACK_PRINTING "Enables stack printing on crashes of SYCL applications" ON)
option(SYCL_LIB_WITH_DEBUG_SYMBOLS "Builds SYCL runtime libraries with debug symbols" OFF)
option(SYCL_ENABLE_IPO "Builds SYCL runtime libraries with interprocedural optimization" OFF)

Expand Down
12 changes: 0 additions & 12 deletions sycl/include/sycl/accessor_image.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -838,9 +838,6 @@ class __SYCL_EBO unsampled_image_accessor :
"Device associated with command group handler does not have "
"aspect::image.");

detail::unsampledImageConstructorNotification(
detail::getSyclObjImpl(ImageRef).get(), this->impl.get(), AccessTarget,
AccessMode, (const void *)typeid(DataT).name(), sizeof(DataT), CodeLoc);
detail::associateWithHandler(CommandGroupHandlerRef, this, AccessTarget);
GDBMethodsAnchor();
}
Expand Down Expand Up @@ -989,9 +986,6 @@ class __SYCL_EBO host_unsampled_image_accessor
PropList) {
addHostUnsampledImageAccessorAndWait(base_class::impl.get());

detail::unsampledImageConstructorNotification(
detail::getSyclObjImpl(ImageRef).get(), this->impl.get(), std::nullopt,
AccessMode, (const void *)typeid(DataT).name(), sizeof(DataT), CodeLoc);
}

/* -- common interface members -- */
Expand Down Expand Up @@ -1149,9 +1143,6 @@ class __SYCL_EBO sampled_image_accessor :
"Device associated with command group handler does not have "
"aspect::image.");

detail::sampledImageConstructorNotification(
detail::getSyclObjImpl(ImageRef).get(), this->impl.get(), AccessTarget,
(const void *)typeid(DataT).name(), sizeof(DataT), CodeLoc);
detail::associateWithHandler(CommandGroupHandlerRef, this, AccessTarget);
GDBMethodsAnchor();
}
Expand Down Expand Up @@ -1276,9 +1267,6 @@ class __SYCL_EBO host_sampled_image_accessor
ImageRef.getSampler(), PropList) {
addHostSampledImageAccessorAndWait(base_class::impl.get());

detail::sampledImageConstructorNotification(
detail::getSyclObjImpl(ImageRef).get(), this->impl.get(), std::nullopt,
(const void *)typeid(DataT).name(), sizeof(DataT), CodeLoc);
}

/* -- common interface members -- */
Expand Down
61 changes: 0 additions & 61 deletions sycl/include/sycl/buffer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>()),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), nullptr, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer(const range<dimensions> &bufferRange, AllocatorT allocator,
Expand All @@ -225,9 +222,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(
allocator)),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), nullptr, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer(T *hostData, const range<dimensions> &bufferRange,
Expand All @@ -238,9 +232,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>()),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), hostData, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer(T *hostData, const range<dimensions> &bufferRange,
Expand All @@ -251,9 +242,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(
allocator)),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), hostData, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

template <typename _T = T>
Expand All @@ -266,9 +254,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>()),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), hostData, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

template <typename _T = T>
Expand All @@ -281,9 +266,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(
allocator)),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), hostData, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer(const std::shared_ptr<T> &hostData,
Expand All @@ -296,10 +278,6 @@ class buffer : public detail::buffer_plain,
allocator),
std::is_const<T>::value),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), (void *)hostData.get(),
(const void *)typeid(T).name(), dimensions, sizeof(T),
detail::rangeToArray(Range).data());
}

buffer(const std::shared_ptr<T[]> &hostData,
Expand All @@ -312,10 +290,6 @@ class buffer : public detail::buffer_plain,
allocator),
std::is_const<T>::value),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), (void *)hostData.get(),
(const void *)typeid(T).name(), dimensions, sizeof(T),
detail::rangeToArray(Range).data());
}

buffer(const std::shared_ptr<T> &hostData,
Expand All @@ -328,10 +302,6 @@ class buffer : public detail::buffer_plain,
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(),
std::is_const<T>::value),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), (void *)hostData.get(),
(const void *)typeid(T).name(), dimensions, sizeof(T),
detail::rangeToArray(Range).data());
}

buffer(const std::shared_ptr<T[]> &hostData,
Expand All @@ -344,10 +314,6 @@ class buffer : public detail::buffer_plain,
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(),
std::is_const<T>::value),
Range(bufferRange) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), (void *)hostData.get(),
(const void *)typeid(T).name(), dimensions, sizeof(T),
detail::rangeToArray(Range).data());
}

template <class InputIterator, int N = dimensions,
Expand Down Expand Up @@ -376,10 +342,6 @@ class buffer : public detail::buffer_plain,
allocator),
detail::iterator_to_const_type_t<InputIterator>::value),
Range(range<1>(std::distance(first, last))) {
size_t r[3] = {Range[0], 0, 0};
buffer_plain::constructorNotification(CodeLoc, (void *)impl.get(), &first,
(const void *)typeid(T).name(),
dimensions, sizeof(T), r);
}

template <class InputIterator, int N = dimensions,
Expand Down Expand Up @@ -408,10 +370,6 @@ class buffer : public detail::buffer_plain,
detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(),
detail::iterator_to_const_type_t<InputIterator>::value),
Range(range<1>(std::distance(first, last))) {
size_t r[3] = {Range[0], 0, 0};
buffer_plain::constructorNotification(CodeLoc, (void *)impl.get(), &first,
(const void *)typeid(T).name(),
dimensions, sizeof(T), r);
}

// This constructor is a prototype for a future SYCL specification
Expand All @@ -427,10 +385,6 @@ class buffer : public detail::buffer_plain,
std::make_unique<detail::SYCLMemObjAllocatorHolder<AllocatorT, T>>(
allocator)),
Range(range<1>(container.size())) {
size_t r[3] = {Range[0], 0, 0};
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), container.data(),
(const void *)typeid(T).name(), dimensions, sizeof(T), r);
}

// This constructor is a prototype for a future SYCL specification
Expand All @@ -447,9 +401,6 @@ class buffer : public detail::buffer_plain,
: buffer_plain(b.impl), Range(subRange),
OffsetInBytes(getOffsetInBytes<T>(baseIndex, b.Range)),
IsSubBuffer(true) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), impl.get(), (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());

if (b.is_sub_buffer())
throw sycl::exception(make_error_code(errc::invalid),
Expand All @@ -466,18 +417,12 @@ class buffer : public detail::buffer_plain,
const detail::code_location CodeLoc = detail::code_location::current())
: buffer_plain(rhs.impl), Range(rhs.Range),
OffsetInBytes(rhs.OffsetInBytes), IsSubBuffer(rhs.IsSubBuffer) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), impl.get(), (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer(buffer &&rhs,
const detail::code_location CodeLoc = detail::code_location::current())
: buffer_plain(std::move(rhs.impl)), Range(rhs.Range),
OffsetInBytes(rhs.OffsetInBytes), IsSubBuffer(rhs.IsSubBuffer) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), impl.get(), (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

buffer &operator=(const buffer &rhs) = default;
Expand Down Expand Up @@ -765,9 +710,6 @@ class buffer : public detail::buffer_plain,
Range{0} {

Range[0] = buffer_plain::getSize() / sizeof(T);
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), &MemObject, (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

void addOrReplaceAccessorProperties(const property_list &PropertyList) {
Expand All @@ -785,9 +727,6 @@ class buffer : public detail::buffer_plain,
const detail::code_location CodeLoc = detail::code_location::current())
: buffer_plain(Impl), Range(reinterpretRange),
OffsetInBytes(reinterpretOffset), IsSubBuffer(isSubBuffer) {
buffer_plain::constructorNotification(
CodeLoc, (void *)impl.get(), Impl.get(), (const void *)typeid(T).name(),
dimensions, sizeof(T), detail::rangeToArray(Range).data());
}

template <typename Type, int N>
Expand Down
2 changes: 2 additions & 0 deletions sycl/source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ function(add_sycl_rt_library LIB_NAME LIB_OBJ_NAME)
OpenCL-Headers
)

target_compile_options(${LIB_OBJ_NAME} PRIVATE -fno-rtti)

# Common link step setup

add_library(${LIB_NAME} SHARED
Expand Down
8 changes: 4 additions & 4 deletions sycl/source/detail/graph/dynamic_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -361,15 +361,15 @@ void dynamic_command_group_impl::finalizeCGFList(
using CGExecKernelSP = std::shared_ptr<sycl::detail::CGExecKernel>;
using CGExecKernelWP = std::weak_ptr<sycl::detail::CGExecKernel>;
for (std::shared_ptr<sycl::detail::CG> CommandGroup : MCommandGroups) {
CGExecKernelSP KernelCG =
std::dynamic_pointer_cast<sycl::detail::CGExecKernel>(CommandGroup);
CGExecKernelSP KernelCG = CommandGroup->getType() == sycl::detail::CGType::Kernel ?
std::static_pointer_cast<sycl::detail::CGExecKernel>(CommandGroup) : nullptr;
std::vector<CGExecKernelWP> Alternatives;

// Add all other command groups except for the current one to the list of
// alternatives
for (auto &OtherCG : MCommandGroups) {
CGExecKernelSP OtherKernelCG =
std::dynamic_pointer_cast<sycl::detail::CGExecKernel>(OtherCG);
CGExecKernelSP OtherKernelCG = OtherCG->getType() == sycl::detail::CGType::Kernel ?
std::static_pointer_cast<sycl::detail::CGExecKernel>(OtherCG) : nullptr;
if (KernelCG != OtherKernelCG) {
Alternatives.push_back(OtherKernelCG);
}
Expand Down
Loading