-
Notifications
You must be signed in to change notification settings - Fork 30
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
Use sycl ext oneapi experimental for complex #1411
Use sycl ext oneapi experimental for complex #1411
Conversation
View rendered docs @ https://intelpython.github.io/dpctl/pulls/1411/index.html |
Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_5 ran successfully. |
02fa4de
to
8a5788c
Compare
Array API standard conformance tests for dpctl=0.15.0rc2=py310ha25a700_3 ran successfully. |
8a5788c
to
3339d48
Compare
Array API standard conformance tests for dpctl=0.15.0rc3=py310ha25a700_5 ran successfully. |
3339d48
to
468110d
Compare
Array API standard conformance tests for dpctl=0.15.0=py310ha25a700_6 ran successfully. |
468110d
to
7c4b0ca
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_9 ran successfully. |
7c4b0ca
to
74b3b53
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_14 ran successfully. |
74b3b53
to
6d7d3fe
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_40 ran successfully. |
6d7d3fe
to
71b85ab
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_51 ran successfully. |
@oleksandr-pavlyk
|
479a969
to
8555f7d
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_83 ran successfully. |
8555f7d
to
49d12ec
Compare
Array API standard conformance tests for dpctl=0.15.1dev0=py310ha25a700_90 ran successfully. |
49d12ec
to
c90c261
Compare
Array API standard conformance tests for dpctl=0.15.1dev1=py310ha25a700_2 ran successfully. |
c90c261
to
affc054
Compare
Array API standard conformance tests for dpctl=0.15.1dev1=py310ha25a700_14 ran successfully. |
This works around use of double precision functions/literals in implementations of these functions in MSVC headers, causing failures to offload on Iris Xe for single precision input citing lack of fp64 support by the hardware. Changes include CL/sycl.hpp to sycl/sycl.hpp per SYCL-2020 spec For every CMake target, where add_sycl_to_target is used, we also run target_compile_options( ${target_name} PRIVATE -fysl-targets=spir64-unknown-unknown,nvptx64-nvidia-cuda ) Add DPCTL_TARGET_CUDA Boolean cmake option Also DPCTL_SYCL_TARGETS parameter can be used to specify targets to build for. DPCTL_TARGET_CUDA could be set via cmake option, or via environment variable, e.g. ``` $ DPCTL_TARGET_CUDA=1 python scripts/build_locally.py --verbose ``` This calls `target_compile_options` to set sycl-targets for targets needing SYCL
affc054
to
6d3be5d
Compare
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_13 ran successfully. |
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_14 ran successfully. |
@ndgrigorian ready to merge, please take a look |
ac42985
to
0f76890
Compare
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_14 ran successfully. |
dpctl/tensor/libtensor/include/kernels/elementwise_functions/sqrt.hpp
Outdated
Show resolved
Hide resolved
Introduced private header to load SYCL's experimental complex header from the right location. The header and implementations respond to USE_SYCL_FOR_COMPLEX_TYPES preprocessor variable. If set, sycl::ext::oneapi::experimental namespace functions are to be used. Otherwise std:: namespace functions will be used instead for complex types. USE_SYCL_FOR_COMPLEX_TYPES is being set in tensor/CMakeLists.txt If USE_SYCL_FOR_COMPLEX_TYPES is not set, std:: functions are used except for sqrt and abs functions. For abs we use hypot(std::real(z), std::imag(z)) and for sqrt we use custom implementation on Windows to avoid failure to offload for single precision type due to unwarranted use of double precision types in the implementation for single precision inputs iin MS VC headers
0f76890
to
c77344c
Compare
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_14 ran successfully. |
dpctl/tensor/libtensor/include/kernels/elementwise_functions/isfinite.hpp
Outdated
Show resolved
Hide resolved
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.
LGTM, thank you @oleksandr-pavlyk ! Nice to see the internal CI passing again.
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_15 ran successfully. |
Array API standard conformance tests for dpctl=0.15.1dev2=py310h15de555_16 ran successfully. |
After transition to oneapi::experimental namespace functions for complex types in gh-1411, all tests pass.
After transition to oneapi::experimental namespace functions for complex types in gh-1411, all tests pass.
After transition to oneapi::experimental namespace functions for complex types in gh-1411, all tests pass.
After transition to oneapi::experimental namespace functions for complex types in gh-1411, all tests pass.
After transition to oneapi::experimental namespace functions for complex types in gh-1411, all tests pass.
This PR applies functions from
sycl::ext:;oneapi::experimental
extension to evaluate trigonometric, hyperbolic unary functions and their inverses.