-
Notifications
You must be signed in to change notification settings - Fork 25
Move _tensor_impl extensions and use it for dpnp
#2755
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
Open
vlad-perevezentsev
wants to merge
19
commits into
include-dpctl-tensor
Choose a base branch
from
move_tensor_impl_ext
base: include-dpctl-tensor
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
d4fd805
Rename folder dpctl to dpctl_ext
vlad-perevezentsev c040713
Add simplify_iteration_space implementation to libtensor
vlad-perevezentsev 14b466f
Extend codespell ignore list for libtensor
vlad-perevezentsev dcc421b
Add copy_and_cast kernels to libtensor
vlad-perevezentsev 5a9c14c
Add copy_usm_ndarray_into_usm_ndarray implementation
vlad-perevezentsev 4f63340
Add pybind11 bindings for dpctl_ext.tensor._tensor_impl
vlad-perevezentsev 634579c
Add CMake build files for dpctl_ext
vlad-perevezentsev 79d40f2
Add empty __init__ to dpctl_ext/
vlad-perevezentsev 7949c17
Enable _same_logical_tensors in _tensor_impl
vlad-perevezentsev 29d6c02
Add device_support_queries to enable default device types
vlad-perevezentsev 936e719
Enable building and packaging of dpctl_ext
vlad-perevezentsev cd85f1e
Use _tensor_impl from dpctl_ext.tensor in dpnp
vlad-perevezentsev 6680790
Disable pylint no-name-in-module for dpctl_ext
vlad-perevezentsev 263b717
Add TODO comments
vlad-perevezentsev 4130c1b
Use default_device_complex_type from dpctl_ext on test_array_api_info.py
vlad-perevezentsev 17ca9ab
Remove unused build_dpctl_ext function
vlad-perevezentsev 79cb2a4
Apply remarks for CMake files
vlad-perevezentsev 4bf080e
Apply remarks for c++ files
vlad-perevezentsev 978afee
Add missing memory and queue checks
vlad-perevezentsev File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -336,3 +336,4 @@ if(DEFINED SKBUILD) | |
| endif() | ||
|
|
||
| add_subdirectory(dpnp) | ||
| add_subdirectory(dpctl_ext) | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,119 @@ | ||
| # -*- coding: utf-8 -*- | ||
| # ***************************************************************************** | ||
| # Copyright (c) 2026, Intel Corporation | ||
| # All rights reserved. | ||
| # | ||
| # Redistribution and use in source and binary forms, with or without | ||
| # modification, are permitted provided that the following conditions are met: | ||
| # - Redistributions of source code must retain the above copyright notice, | ||
| # this list of conditions and the following disclaimer. | ||
| # - Redistributions in binary form must reproduce the above copyright notice, | ||
| # this list of conditions and the following disclaimer in the documentation | ||
| # and/or other materials provided with the distribution. | ||
| # - Neither the name of the copyright holder nor the names of its contributors | ||
| # may be used to endorse or promote products derived from this software | ||
| # without specific prior written permission. | ||
| # | ||
| # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
| # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
| # THE POSSIBILITY OF SUCH DAMAGE. | ||
| # ***************************************************************************** | ||
|
|
||
| # TODO: rework this logic to remove current duplication | ||
| if(WIN32) | ||
| string( | ||
| CONCAT WARNING_FLAGS | ||
| "-Wall " | ||
| "-Wextra " | ||
| "-Winit-self " | ||
| "-Wunused-function " | ||
| "-Wuninitialized " | ||
| "-Wmissing-declarations " | ||
| "-Wstrict-prototypes " | ||
| "-Wno-unused-parameter " | ||
| ) | ||
| string(CONCAT SDL_FLAGS "/GS " "/DynamicBase ") | ||
| set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /Ox ${WARNING_FLAGS} ${SDL_FLAGS}") | ||
| set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Ox ${WARNING_FLAGS} ${SDL_FLAGS}") | ||
| set(CMAKE_C_FLAGS_DEBUG | ||
| "${CMAKE_C_FLAGS_DEBUG} ${WARNING_FLAGS} ${SDL_FLAGS} -O0 -g1 -DDEBUG -Xsycl-target-frontend=spir64 \"-g0\"" | ||
| ) | ||
| set(CMAKE_CXX_FLAGS_DEBUG | ||
| "${CMAKE_CXX_FLAGS_DEBUG} ${WARNING_FLAGS} ${SDL_FLAGS} -O0 -g1 -DDEBUG -Xsycl-target-frontend=spir64 \"-g0\"" | ||
| ) | ||
| set(CMAKE_C_FLAGS_COVERAGE | ||
| "${CMAKE_C_FLAGS_DEBUG} ${WARNING_FLAGS} ${SDL_FLAGS} -O1 -g1 -DDEBUG" | ||
| ) | ||
| set(CMAKE_CXX_FLAGS_COVERAGE | ||
| "${CMAKE_CXX_FLAGS_DEBUG} ${WARNING_FLAGS} ${SDL_FLAGS} -O1 -g1 -DDEBUG" | ||
| ) | ||
| set(CMAKE_MODULE_LINKER_FLAGS_COVERAGE "${CMAKE_MODULE_LINKER_FLAGS_DEBUG}") | ||
| set(DPCTL_LDFLAGS "/NXCompat;/DynamicBase") | ||
| mark_as_advanced( | ||
| CMAKE_CXX_FLAGS_COVERAGE | ||
| CMAKE_C_FLAGS_COVERAGE | ||
| CMAKE_MODULE_LINKER_FLAGS_COVERAGE | ||
| ) | ||
| elseif(UNIX) | ||
| string( | ||
| CONCAT WARNING_FLAGS | ||
| "-Wall " | ||
| "-Wextra " | ||
| "-Winit-self " | ||
| "-Wunused-function " | ||
| "-Wuninitialized " | ||
| "-Wmissing-declarations " | ||
| "-Wstrict-prototypes " | ||
| "-Wno-unused-parameter " | ||
| "-fdiagnostics-color=auto " | ||
| ) | ||
| string( | ||
| CONCAT SDL_FLAGS | ||
| "-fstack-protector " | ||
| "-fstack-protector-all " | ||
| "-fpic " | ||
| "-fPIC " | ||
| "-D_FORTIFY_SOURCE=2 " | ||
| "-Wformat " | ||
| "-Wformat-security " | ||
| # "-fno-strict-overflow " # no-strict-overflow is implied by -fwrapv | ||
| "-fno-delete-null-pointer-checks " | ||
| "-fwrapv " | ||
| ) | ||
| string(CONCAT CFLAGS "${WARNING_FLAGS}" "${SDL_FLAGS}") | ||
| string(CONCAT CXXFLAGS "${WARNING_FLAGS}" "${SDL_FLAGS}") | ||
| set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O3 ${CFLAGS}") | ||
| set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 ${CXXFLAGS}") | ||
| set(CMAKE_C_FLAGS_DEBUG | ||
| "${CMAKE_C_FLAGS_DEBUG} ${CFLAGS} -O0 -g -DDEBUG -Xsycl-target-frontend=spir64 \"-g0\"" | ||
| ) | ||
| set(CMAKE_CXX_FLAGS_DEBUG | ||
| "${CMAKE_CXX_FLAGS_DEBUG} ${CXXFLAGS} -O0 -g -DDEBUG -Xsycl-target-frontend=spir64 \"-g0\"" | ||
| ) | ||
| set(CMAKE_C_FLAGS_COVERAGE "${CMAKE_C_FLAGS_DEBUG} ${CFLAGS} -O1 -g1 -DDEBUG") | ||
| set(CMAKE_CXX_FLAGS_COVERAGE "${CMAKE_CXX_FLAGS_DEBUG} ${CXXFLAGS} -O1 -g1 -DDEBUG") | ||
| set(CMAKE_MODULE_LINKER_FLAGS_COVERAGE "${CMAKE_MODULE_LINKER_FLAGS_DEBUG}") | ||
| set(DPCTL_LDFLAGS "-z,noexecstack,-z,relro,-z,now") | ||
| mark_as_advanced( | ||
| CMAKE_CXX_FLAGS_COVERAGE | ||
| CMAKE_C_FLAGS_COVERAGE | ||
| CMAKE_MODULE_LINKER_FLAGS_COVERAGE | ||
| ) | ||
| else() | ||
| message(FATAL_ERROR "Unsupported system.") | ||
| endif() | ||
|
|
||
| # at build time create include/ directory and copy header files over | ||
| # set(DPCTL_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include) | ||
|
|
||
| set(CMAKE_INSTALL_RPATH "$ORIGIN") | ||
|
|
||
| add_subdirectory(tensor) | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # ***************************************************************************** | ||
| # Copyright (c) 2026, Intel Corporation | ||
| # All rights reserved. | ||
| # | ||
| # Redistribution and use in source and binary forms, with or without | ||
| # modification, are permitted provided that the following conditions are met: | ||
| # - Redistributions of source code must retain the above copyright notice, | ||
| # this list of conditions and the following disclaimer. | ||
| # - Redistributions in binary form must reproduce the above copyright notice, | ||
| # this list of conditions and the following disclaimer in the documentation | ||
| # and/or other materials provided with the distribution. | ||
| # - Neither the name of the copyright holder nor the names of its contributors | ||
| # may be used to endorse or promote products derived from this software | ||
| # without specific prior written permission. | ||
| # | ||
| # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
| # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
| # THE POSSIBILITY OF SUCH DAMAGE. | ||
| # ***************************************************************************** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,179 @@ | ||
| # -*- coding: utf-8 -*- | ||
| # ***************************************************************************** | ||
| # Copyright (c) 2026, Intel Corporation | ||
| # All rights reserved. | ||
| # | ||
| # Redistribution and use in source and binary forms, with or without | ||
| # modification, are permitted provided that the following conditions are met: | ||
| # - Redistributions of source code must retain the above copyright notice, | ||
| # this list of conditions and the following disclaimer. | ||
| # - Redistributions in binary form must reproduce the above copyright notice, | ||
| # this list of conditions and the following disclaimer in the documentation | ||
| # and/or other materials provided with the distribution. | ||
| # - Neither the name of the copyright holder nor the names of its contributors | ||
| # may be used to endorse or promote products derived from this software | ||
| # without specific prior written permission. | ||
| # | ||
| # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
| # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
| # THE POSSIBILITY OF SUCH DAMAGE. | ||
| # ***************************************************************************** | ||
|
|
||
| find_package(Python COMPONENTS Development) | ||
|
|
||
| if(WIN32) | ||
| if(${CMAKE_VERSION} VERSION_LESS "3.27") | ||
| # this is a work-around for target_link_options inserting option after -link option, cause | ||
| # linker to ignore it. | ||
| set(CMAKE_CXX_LINK_FLAGS | ||
| "${CMAKE_CXX_LINK_FLAGS} -fsycl-device-code-split=per_kernel" | ||
| ) | ||
| endif() | ||
| endif() | ||
|
|
||
| # TODO: reuse this library for dpnp ufunc extension build | ||
| set(_static_lib_sources | ||
vlad-perevezentsev marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/simplify_iteration_space.cpp | ||
| ) | ||
| set(_tensor_impl_sources | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/tensor_ctors.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/accumulators.cpp | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_and_cast_usm_to_usm.cpp | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_as_contig.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_numpy_ndarray_into_usm_ndarray.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_for_reshape.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_for_roll.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/linear_sequences.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/integer_advanced_indexing.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/boolean_advanced_indexing.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/eye_ctor.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/full_ctor.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/zeros_ctor.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/triul_ctor.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/where.cpp | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/device_support_queries.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/repeat.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/clip.cpp | ||
| ) | ||
|
|
||
| set(_static_lib_trgt simplify_iteration_space) | ||
|
|
||
| add_library(${_static_lib_trgt} STATIC ${_static_lib_sources}) | ||
| target_include_directories( | ||
| ${_static_lib_trgt} | ||
| PRIVATE | ||
| # ${Python_INCLUDE_DIRS} | ||
| # ${Dpctl_INCLUDE_DIR} | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/include | ||
| ) | ||
| target_link_libraries(${_static_lib_trgt} PRIVATE pybind11::headers Python::Python) | ||
| set_target_properties(${_static_lib_trgt} PROPERTIES POSITION_INDEPENDENT_CODE ON) | ||
|
|
||
| set(_py_trgts) | ||
|
|
||
| set(python_module_name _tensor_impl) | ||
| pybind11_add_module(${python_module_name} MODULE ${_tensor_impl_sources}) | ||
| add_sycl_to_target(TARGET ${python_module_name} SOURCES ${_tensor_impl_sources}) | ||
| target_link_libraries(${python_module_name} PRIVATE ${_static_lib_trgt}) | ||
| list(APPEND _py_trgts ${python_module_name}) | ||
|
|
||
| set(_clang_prefix "") | ||
| if(WIN32) | ||
| set(_clang_prefix "/clang:") | ||
| endif() | ||
|
|
||
| set(_no_fast_math_sources | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/copy_and_cast_usm_to_usm.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/full_ctor.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/linear_sequences.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/clip.cpp | ||
| # ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/where.cpp | ||
| ) | ||
| #list( | ||
| #APPEND _no_fast_math_sources | ||
| # ${_elementwise_sources} | ||
| # ${_reduction_sources} | ||
| # ${_sorting_sources} | ||
| # ${_linalg_sources} | ||
| # ${_accumulator_sources} | ||
| #) | ||
|
|
||
| foreach(_src_fn ${_no_fast_math_sources}) | ||
| get_source_file_property(_cmpl_options_prop ${_src_fn} COMPILE_OPTIONS) | ||
| set(_combined_options_prop ${_cmpl_options_prop} "${_clang_prefix}-fno-fast-math") | ||
| set_source_files_properties( | ||
| ${_src_fn} | ||
| PROPERTIES COMPILE_OPTIONS "${_combined_options_prop}" | ||
| ) | ||
| endforeach() | ||
|
|
||
| set(_compiler_definitions "") | ||
|
|
||
| set(_linker_options "LINKER:${DPNP_LDFLAGS}") | ||
| foreach(python_module_name ${_py_trgts}) | ||
| target_compile_options( | ||
| ${python_module_name} | ||
| PRIVATE -fno-sycl-id-queries-fit-in-int | ||
| ) | ||
| target_link_options( | ||
| ${python_module_name} | ||
| PRIVATE -fsycl-device-code-split=per_kernel | ||
| ) | ||
| # TODO: expand DPCTL_OFFLOAD_COMPRESS to the whole dpnp level | ||
| if(DPCTL_OFFLOAD_COMPRESS) | ||
vlad-perevezentsev marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| target_link_options(${python_module_name} PRIVATE --offload-compress) | ||
| endif() | ||
|
|
||
| target_include_directories( | ||
| ${python_module_name} | ||
| PRIVATE | ||
| ${CMAKE_SOURCE_DIR}/dpnp/backend/include | ||
| ${Dpctl_INCLUDE_DIR} | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/include | ||
| ${CMAKE_CURRENT_SOURCE_DIR}/libtensor/source/ | ||
| ) | ||
| target_link_options(${python_module_name} PRIVATE ${_linker_options}) | ||
| if(DPCTL_GENERATE_COVERAGE) | ||
| if(DPCTL_GENERATE_COVERAGE_FOR_PYBIND11_EXTENSIONS) | ||
| target_compile_options( | ||
| ${python_module_name} | ||
| PRIVATE -fprofile-instr-generate -fcoverage-mapping | ||
| ) | ||
| endif() | ||
| target_link_options( | ||
| ${python_module_name} | ||
| PRIVATE -fprofile-instr-generate -fcoverage-mapping | ||
| ) | ||
| endif() | ||
| if(_dpnp_sycl_targets) | ||
| # make fat binary | ||
| target_compile_options( | ||
| ${python_module_name} | ||
| PRIVATE ${_dpnp_sycl_target_compile_options} | ||
| ) | ||
| target_link_options( | ||
| ${python_module_name} | ||
| PRIVATE ${_dpnp_sycl_target_link_options} | ||
| ) | ||
| endif() | ||
| # TODO: update source so they reference individual libraries instead of | ||
| # dpctl4pybind11.hpp. It will allow to simplify dependency tree | ||
| # NOTE: dpctl C-API is resolved at runtime via Python | ||
| # target_link_libraries(${python_module_name} PRIVATE DpctlCAPI) | ||
| if(DPNP_WITH_REDIST) | ||
| set_target_properties( | ||
| ${python_module_name} | ||
| PROPERTIES INSTALL_RPATH "$ORIGIN/../../../.." | ||
| ) | ||
| endif() | ||
| # TODO: revert to `DESTINATION "dpctl/tensor"` | ||
| install(TARGETS ${python_module_name} DESTINATION "dpctl_ext/tensor") | ||
| endforeach() | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # ***************************************************************************** | ||
| # Copyright (c) 2026, Intel Corporation | ||
| # All rights reserved. | ||
| # | ||
| # Redistribution and use in source and binary forms, with or without | ||
| # modification, are permitted provided that the following conditions are met: | ||
| # - Redistributions of source code must retain the above copyright notice, | ||
| # this list of conditions and the following disclaimer. | ||
| # - Redistributions in binary form must reproduce the above copyright notice, | ||
| # this list of conditions and the following disclaimer in the documentation | ||
| # and/or other materials provided with the distribution. | ||
| # - Neither the name of the copyright holder nor the names of its contributors | ||
| # may be used to endorse or promote products derived from this software | ||
| # without specific prior written permission. | ||
| # | ||
| # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
| # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
| # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
| # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
| # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
| # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
| # THE POSSIBILITY OF SUCH DAMAGE. | ||
| # ***************************************************************************** | ||
antonwolfy marked this conversation as resolved.
Show resolved
Hide resolved
|
||
File renamed without changes.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.