-
Notifications
You must be signed in to change notification settings - Fork 730
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
[DO NOT MERGE][ABI-Break][SYCL] ABI-neutralize exception constructor #13369
Conversation
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
@steffenlarsen |
Signed-off-by: Byoungro So <byoungro.so@intel.com>
// This file is intended be used to break dependency cycles due to | ||
// exception.hpp. In some header files where exceptions are thrown, it has to | ||
// #include <sycl/exception.hpp> which could lead to a cyclic dependency. In | ||
// that case, it can utilize this work-around. This helper class is not intended | ||
// to replace all throwing exception cases. | ||
// | ||
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. | ||
// See https://llvm.org/LICENSE.txt for license information. | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need to make it part of ABI: https://godbolt.org/z/bEbW181vn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ABI-break is caused by changes to exception constructors, not because this new helper function.
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
Signed-off-by: Byoungro So <byoungro.so@intel.com>
I will close this PR when #13560 is merged. |
To support ABI-neutral feature, a constructor of the sycl::exception class should take detail::string_view instead of std::string.
Also, to break cyclic dependencies, I introduced exception_helper.hpp/.cpp to throw an invalid parameter exception from the cpp file.