Skip to content

Commit 0c3e4c1

Browse files
committed
Merge remote-tracking branch 'origin' into hari/pr_29392_dupe
2 parents 83ec37d + 682936c commit 0c3e4c1

192 files changed

Lines changed: 6575 additions & 1915 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/linux_cuda_plugin_ci.yml

Lines changed: 17 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
name: Build Linux CUDA Plugin EP x64 Release
2323
uses: ./.github/workflows/reusable_linux_build.yml
2424
with:
25-
pool_name: "onnxruntime-github-Ubuntu2204-AMD-CPU"
25+
pool_name: "onnxruntime-github-Ubuntu2204-AMD-CPU" # Build pool
2626
build_config: Release
2727
architecture: x64
2828
dockerfile_path: tools/ci_build/github/linux/docker/Dockerfile.manylinux2_28_cuda
@@ -39,6 +39,7 @@ jobs:
3939
--cudnn_home=/usr/local/cuda-13.0
4040
--enable_cuda_profiling
4141
--cmake_extra_defines CMAKE_CUDA_ARCHITECTURES=86
42+
--cmake_extra_defines onnxruntime_BUILD_UNIT_TESTS=ON
4243
--cmake_extra_defines onnxruntime_QUICK_BUILD=ON
4344
--cmake_extra_defines onnxruntime_BUILD_CUDA_EP_AS_PLUGIN=ON
4445
python_path_prefix: 'PATH=/opt/python/cp312-cp312/bin:$PATH'
@@ -55,6 +56,7 @@ jobs:
5556
runs-on:
5657
- self-hosted
5758
- "1ES.Pool=onnxruntime-github-linux-a10"
59+
- "1ES.ImageOverride=onnxruntime-ubuntu2204-CUDA-A10-Test"
5860
- "JobId=test-linux-cuda-plugin-x64-release-${{ github.run_id }}-${{ github.run_number }}-${{ github.run_attempt }}"
5961
permissions:
6062
contents: read
@@ -109,63 +111,38 @@ jobs:
109111
"${{ steps.build_docker_image_step.outputs.full-image-name }}" \
110112
nvidia-smi
111113
112-
# --- Install the ORT wheel and run CUDA plugin EP tests ---
113-
- name: Run CUDA Plugin EP Python Tests
114+
- name: Run CUDA Plugin EP C++ Tests
114115
run: |
115116
docker run --rm --gpus all \
116117
-v ${{ github.workspace }}:/onnxruntime_src \
117118
-v ${{ runner.temp }}/Release:/build/Release \
118119
-e NVIDIA_VISIBLE_DEVICES=all \
120+
-e ORT_UNIT_TEST_MAIN_DYNAMIC_PLUGIN_EP_CONFIG_JSON='{"ep_library_registration_name":"CUDAExecutionProvider","ep_library_path":"libonnxruntime_providers_cuda.so","selected_ep_name":"CUDAExecutionProvider","tests_to_skip":["BeamSearchTest.*","ContribOpAttentionTest.AttentionPastState_dynamic","ContribOpAttentionTest.Attention_Mask1D_Fp32_B2_S64","ContribOpAttentionTest.Attention_Mask2D_Fp32_B2_S32","ConvTest.Conv2D_MatMul_*","CudaPluginArenaTest.DeviceAllocator_ArenaReusesMemory","CudaPluginArenaTest.DeviceAllocator_CudaMemoryIsValid","CudaPluginArenaTest.DeviceAllocator_IsArena","CudaPluginArenaTest.DeviceAllocator_MultipleAllocations","DeformConvTest.Group1OffsetGroup2","GRUTest.*","GreedySearchTest.*","InferenceSessionTests.Test2LayerNestedSubgraph","InferenceSessionTests.Test3LayerNestedSubgraph","InferenceSessionTests.TestArenaShrinkageAfterRun","LSTMTest.*","LogSoftmaxOperator.*","LongformerAttentionTest.*","LoraAdapterTest.VerifyDeviceCopy","PackedAttentionTest.*","PlannerTest.MultiStream","PlannerTest.MultiStream1StreamWaitFor2Streams","PlannerTest.MultiStream2NodesSameStreamConsumedBy1NodeInDifferentStream","PlannerTest.MultiStreamCudaEPNodeCPUOutput","PlannerTest.MultiStreamMultiOutput","RNNTest.*","ReductionOpTest.ArgMax2D_select_last","ReductionOpTest.ArgMin_do_not_keepdims_2_select_last","SamplingTest.*","Scan.MixedExecutionProvidersUnknownDimInSubgraphOutput","Scan8.*","SessionStateTest.TestLayeringPartitioning","SessionStateTest.TestResourceAwarePartitioning_LargeLimit","SessionStateTest.TestResourceAwarePartitioning_NoLimit","SkipGroupNormTest.*","TopKOperator.NthElementBFloat16_NegativeVals"]}' \
119121
${{ steps.build_docker_image_step.outputs.full-image-name }} \
120122
bash -c "
121123
set -ex
122-
export PATH=/opt/python/cp312-cp312/bin:\$PATH
123-
# Ensure libcudart.so.13 is findable regardless of host-runner NVIDIA Container Toolkit configuration.
124-
# The CUDA runtime library lives in the container image at /usr/local/cuda-13.0/lib64, but the
125-
# LD_LIBRARY_PATH may not include this path when the runner's NVIDIA toolkit only mounts driver
126-
# libraries at /usr/local/nvidia/lib64.
127-
export LD_LIBRARY_PATH=/usr/local/cuda-13.0/lib64:\${LD_LIBRARY_PATH:-}
128-
129-
# Install the ORT wheel
130-
python -m pip install /build/Release/Release/dist/onnxruntime*.whl
131-
132-
# Install test dependencies
133-
python -m pip install numpy onnx
134-
python -m pip install torch --index-url https://download.pytorch.org/whl/cpu
135-
136-
# Set plugin path and run tests
137-
export ORT_CUDA_PLUGIN_PATH=/build/Release/Release/libonnxruntime_providers_cuda_plugin.so
138-
echo \"ORT_CUDA_PLUGIN_PATH=\$ORT_CUDA_PLUGIN_PATH\"
139-
ls -la \$ORT_CUDA_PLUGIN_PATH
140-
141-
cd /onnxruntime_src/onnxruntime/test/python/transformers
142-
python test_cuda_plugin_ep.py
124+
export LD_LIBRARY_PATH=/build/Release/Release:/usr/local/cuda-13.0/lib64:\${LD_LIBRARY_PATH:-}
125+
cd /build/Release/Release
126+
./onnxruntime_test_all
127+
./onnxruntime_provider_test
143128
"
144129
145-
# --- Run the CUDA plugin EP C++ GoogleTest binary ---
146-
# onnxruntime_provider_test is built into the artifact and links the plugin tests
147-
# (gated by ORT_UNIT_TEST_HAS_CUDA_PLUGIN_EP). These tests register the plugin .so via
148-
# GetSharedLibraryFileName("onnxruntime_providers_cuda_plugin"), which returns the
149-
# platform-specific filename without a directory component. Run from /build/Release/Release
150-
# so that filename resolves to the plugin .so built there.
151-
# The filter covers every CUDA plugin EP suite linked into this binary:
152-
# CudaPlugin* -> CudaPluginUserStreamGraphTest, CudaPluginArenaTest,
153-
# CudaPluginPartitioningTest, CudaPluginProfilingTest
154-
# CudaResourcePartitioning* -> CudaResourcePartitioningTest
155-
- name: Run CUDA Plugin EP C++ Tests
130+
- name: Run CUDA Plugin EP Python Tests
156131
run: |
157132
docker run --rm --gpus all \
158133
-v ${{ github.workspace }}:/onnxruntime_src \
159134
-v ${{ runner.temp }}/Release:/build/Release \
160135
-e NVIDIA_VISIBLE_DEVICES=all \
136+
-e ORT_TEST_CUDA_PLUGIN_EP=1 \
161137
${{ steps.build_docker_image_step.outputs.full-image-name }} \
162138
bash -c "
163139
set -ex
164140
export PATH=/opt/python/cp312-cp312/bin:\$PATH
165-
# Make libcudart.so.13 (and the plugin's CUDA deps) findable; see note above.
166141
export LD_LIBRARY_PATH=/build/Release/Release:/usr/local/cuda-13.0/lib64:\${LD_LIBRARY_PATH:-}
167-
168-
cd /build/Release/Release
169-
ls -la onnxruntime_provider_test libonnxruntime_providers_cuda_plugin.so
170-
./onnxruntime_provider_test --gtest_filter='CudaPlugin*:CudaResourcePartitioning*'
142+
python -m pip install /build/Release/Release/dist/onnxruntime*.whl
143+
python -m pip install numpy onnx
144+
python -m pip install torch --index-url https://download.pytorch.org/whl/cpu
145+
cd /onnxruntime_src/onnxruntime/test/python/transformers
146+
python test_cuda_plugin_ep.py
171147
"
148+

.github/workflows/windows_cuda_no_cudnn.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ jobs:
192192
shell: cmd
193193

194194
- name: Install torch for CPU only
195-
run: python -m pip install torch
195+
run: python -m pip install torch --index-url https://download.pytorch.org/whl/cpu
196196
working-directory: ${{ github.workspace }}
197197
shell: cmd
198198

@@ -229,7 +229,7 @@ jobs:
229229
- name: Verify CUDA plugin has no direct cuDNN dependency
230230
shell: pwsh
231231
run: |
232-
$pluginPath = "${{ runner.temp }}\build\Release\Release\onnxruntime_providers_cuda_plugin.dll"
232+
$pluginPath = "${{ runner.temp }}\build\Release\Release\onnxruntime_providers_cuda.dll"
233233
if (-not (Test-Path $pluginPath)) {
234234
Write-Error "CUDA plugin EP library not found at $pluginPath"
235235
exit 1
@@ -245,10 +245,8 @@ jobs:
245245
working-directory: ${{ github.workspace }}\onnxruntime\test\python\transformers
246246
shell: pwsh
247247
run: |
248-
$env:ORT_CUDA_PLUGIN_PATH = "${{ runner.temp }}\build\Release\Release\onnxruntime_providers_cuda_plugin.dll"
249248
$env:ORT_TEST_CUDA_PLUGIN_EP = "1"
250249
$env:ORT_TEST_CUDA_PLUGIN_NO_CUDNN = "1"
251-
Write-Host "ORT_CUDA_PLUGIN_PATH=$env:ORT_CUDA_PLUGIN_PATH"
252250
python test_cuda_plugin_ep.py
253251
if ($lastExitCode -ne 0) {
254252
exit $lastExitCode

.github/workflows/windows_cuda_plugin.yml

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ jobs:
157157
shell: cmd
158158

159159
- name: Install torch for CPU only
160-
run: python -m pip install torch
160+
run: python -m pip install torch --index-url https://download.pytorch.org/whl/cpu
161161
working-directory: ${{ github.workspace }}
162162
shell: cmd
163163

@@ -194,20 +194,32 @@ jobs:
194194
shell: pwsh
195195
run: nvidia-smi
196196

197+
- name: Run Tests
198+
working-directory: ${{ runner.temp }}\build\Release\Release
199+
shell: pwsh
200+
run: |
201+
$env:ORT_UNIT_TEST_MAIN_DYNAMIC_PLUGIN_EP_CONFIG_JSON = '{"ep_library_registration_name":"CUDAExecutionProvider","ep_library_path":"onnxruntime_providers_cuda.dll","selected_ep_name":"CUDAExecutionProvider","tests_to_skip":["BeamSearchTest.*","ContribOpAttentionTest.AttentionPastState_dynamic","ContribOpAttentionTest.Attention_Mask1D_Fp32_B2_S64","ContribOpAttentionTest.Attention_Mask2D_Fp32_B2_S32","ConvTest.Conv2D_MatMul_*","ConvTest.Conv3D_2","CudaPluginArenaTest.DeviceAllocator_ArenaReusesMemory","CudaPluginArenaTest.DeviceAllocator_CudaMemoryIsValid","CudaPluginArenaTest.DeviceAllocator_IsArena","CudaPluginArenaTest.DeviceAllocator_MultipleAllocations","DeformConvTest.Group1OffsetGroup2","GRUTest.*","GreedySearchTest.*","InferenceSessionTests.Test2LayerNestedSubgraph","InferenceSessionTests.Test3LayerNestedSubgraph","InferenceSessionTests.TestArenaShrinkageAfterRun","LSTMTest.*","LogSoftmaxOperator.*","LongformerAttentionTest.*","LoraAdapterTest.VerifyDeviceCopy","PackedAttentionTest.*","PlannerTest.MultiStream","PlannerTest.MultiStream1StreamWaitFor2Streams","PlannerTest.MultiStream2NodesSameStreamConsumedBy1NodeInDifferentStream","PlannerTest.MultiStreamCudaEPNodeCPUOutput","PlannerTest.MultiStreamMultiOutput","RNNTest.*","ReductionOpTest.ArgMax2D_select_last","ReductionOpTest.ArgMin_do_not_keepdims_2_select_last","SamplingTest.*","Scan.MixedExecutionProvidersUnknownDimInSubgraphOutput","Scan8.*","SessionStateTest.TestLayeringPartitioning","SessionStateTest.TestResourceAwarePartitioning_LargeLimit","SessionStateTest.TestResourceAwarePartitioning_NoLimit","SkipGroupNormTest.*","TopKOperator.NthElementBFloat16_NegativeVals"]}'
202+
203+
.\onnxruntime_test_all.exe
204+
if ($lastExitCode -ne 0) {
205+
exit $lastExitCode
206+
}
207+
208+
.\onnxruntime_provider_test.exe
209+
if ($lastExitCode -ne 0) {
210+
exit $lastExitCode
211+
}
212+
197213
- name: Run CUDA Plugin EP Python Tests
198214
working-directory: ${{ github.workspace }}\onnxruntime\test\python\transformers
199215
shell: pwsh
200216
run: |
201-
$env:ORT_CUDA_PLUGIN_PATH = "${{ runner.temp }}\build\Release\Release\onnxruntime_providers_cuda_plugin.dll"
202-
Write-Host "ORT_CUDA_PLUGIN_PATH=$env:ORT_CUDA_PLUGIN_PATH"
203-
if (-not (Test-Path $env:ORT_CUDA_PLUGIN_PATH)) {
204-
Write-Error "CUDA plugin EP library not found at $env:ORT_CUDA_PLUGIN_PATH"
205-
exit 1
206-
}
217+
$env:ORT_TEST_CUDA_PLUGIN_EP = "1"
207218
python test_cuda_plugin_ep.py
208219
if ($lastExitCode -ne 0) {
209220
exit $lastExitCode
210221
}
222+
211223
env:
212224
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
213225
setVcvars: true

VERSION_NUMBER

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.28.0
1+
1.29.0

cmake/CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ option(onnxruntime_USE_CUDA "Build with CUDA support" OFF)
7676
cmake_dependent_option(onnxruntime_ENABLE_CUDA_EP_INTERNAL_TESTS "Build with CUDA unit tests" OFF "onnxruntime_USE_CUDA;onnxruntime_BUILD_UNIT_TESTS" OFF)
7777

7878
cmake_dependent_option(onnxruntime_USE_CUDA_NHWC_OPS "Build CUDA with NHWC op support" ON "onnxruntime_USE_CUDA" OFF)
79-
cmake_dependent_option(onnxruntime_BUILD_CUDA_EP_AS_PLUGIN "Build CUDA EP as a separate plugin shared library" OFF "onnxruntime_USE_CUDA" OFF)
79+
cmake_dependent_option(onnxruntime_BUILD_CUDA_EP_AS_PLUGIN "Build CUDA EP as a separate plugin shared library instead of the legacy in-tree provider" OFF "onnxruntime_USE_CUDA" OFF)
8080
option(onnxruntime_CUDA_MINIMAL "Build CUDA without any operations apart from memcpy ops. Usefuel for a very minial TRT build" OFF)
8181
option(onnxruntime_ENABLE_CUDA_LINE_NUMBER_INFO "When building with CUDA support, generate device code line number information." OFF)
8282
option(onnxruntime_USE_OPENVINO "Build with OpenVINO support" OFF)
@@ -1800,10 +1800,6 @@ foreach(onnxruntime_cmake_file ${ONNXRUNTIME_CMAKE_FILES})
18001800
include(${onnxruntime_cmake_file}.cmake)
18011801
endforeach()
18021802

1803-
# CUDA EP Plugin build (independent shared library)
1804-
if (onnxruntime_USE_CUDA AND onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
1805-
include(onnxruntime_providers_cuda_plugin.cmake)
1806-
endif()
18071803
if (UNIX)
18081804
option(BUILD_PKGCONFIG_FILES "Build and install pkg-config files" ON)
18091805
else()

cmake/onnxruntime_java.cmake

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,12 @@ if (WIN32)
162162
if (TARGET onnxruntime_providers_shared)
163163
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_shared> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_FILE_NAME:onnxruntime_providers_shared>)
164164
endif()
165-
if (onnxruntime_USE_CUDA)
165+
if (onnxruntime_USE_CUDA AND NOT onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
166166
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_cuda> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_FILE_NAME:onnxruntime_providers_cuda>)
167167
endif()
168+
if (onnxruntime_USE_CUDA AND onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
169+
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_cuda_plugin> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_FILE_NAME:onnxruntime_providers_cuda_plugin>)
170+
endif()
168171
if (onnxruntime_USE_DNNL)
169172
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_dnnl> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_FILE_NAME:onnxruntime_providers_dnnl>)
170173
endif()
@@ -210,9 +213,12 @@ else()
210213
if (TARGET onnxruntime_providers_shared)
211214
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_shared> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_LINKER_FILE_NAME:onnxruntime_providers_shared>)
212215
endif()
213-
if (onnxruntime_USE_CUDA)
216+
if (onnxruntime_USE_CUDA AND NOT onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
214217
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_cuda> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_LINKER_FILE_NAME:onnxruntime_providers_cuda>)
215218
endif()
219+
if (onnxruntime_USE_CUDA AND onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
220+
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_cuda_plugin> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_LINKER_FILE_NAME:onnxruntime_providers_cuda_plugin>)
221+
endif()
216222
if (onnxruntime_USE_DNNL)
217223
add_custom_command(TARGET onnxruntime4j_jni POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different $<TARGET_FILE:onnxruntime_providers_dnnl> ${JAVA_PACKAGE_LIB_DIR}/$<TARGET_LINKER_FILE_NAME:onnxruntime_providers_dnnl>)
218224
endif()

cmake/onnxruntime_providers.cmake

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ endfunction()
6262
if(onnxruntime_USE_VITISAI)
6363
set(PROVIDERS_VITISAI onnxruntime_providers_vitisai)
6464
endif()
65-
if(onnxruntime_USE_CUDA)
65+
if(onnxruntime_USE_CUDA AND NOT onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
6666
set(PROVIDERS_CUDA onnxruntime_providers_cuda)
6767
endif()
6868
if(onnxruntime_USE_COREML)
@@ -114,9 +114,12 @@ if(onnxruntime_USE_SNPE)
114114
endif()
115115

116116
include(onnxruntime_providers_cpu.cmake)
117-
if (onnxruntime_USE_CUDA)
117+
if (onnxruntime_USE_CUDA AND NOT onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
118118
include(onnxruntime_providers_cuda.cmake)
119119
endif()
120+
if (onnxruntime_USE_CUDA AND onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
121+
include(onnxruntime_providers_cuda_plugin.cmake)
122+
endif()
120123

121124
if (onnxruntime_USE_DNNL)
122125
include(onnxruntime_providers_dnnl.cmake)

cmake/onnxruntime_providers_cuda_plugin.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Licensed under the MIT License.
33

44
# Build the CUDA Execution Provider as a plugin shared library.
5-
# This file is included from the main CMakeLists.txt when onnxruntime_BUILD_CUDA_EP_AS_PLUGIN=ON.
5+
# This file is included from onnxruntime_providers.cmake when onnxruntime_BUILD_CUDA_EP_AS_PLUGIN=ON.
66

77
message(STATUS "Building CUDA EP as plugin shared library")
88

@@ -458,7 +458,7 @@ endif()
458458

459459
# Set output name and solution folder
460460
set_target_properties(onnxruntime_providers_cuda_plugin PROPERTIES
461-
OUTPUT_NAME "onnxruntime_providers_cuda_plugin"
461+
OUTPUT_NAME "onnxruntime_providers_cuda"
462462
FOLDER "ONNXRuntime"
463463
)
464464

cmake/onnxruntime_python.cmake

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1085,7 +1085,7 @@ if (DEFINED ENV{OPENVINO_MANYLINUX})
10851085
)
10861086
endif()
10871087

1088-
if (onnxruntime_USE_CUDA)
1088+
if (onnxruntime_USE_CUDA AND NOT onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
10891089
add_custom_command(
10901090
TARGET onnxruntime_pybind11_state POST_BUILD
10911091
COMMAND ${CMAKE_COMMAND} -E copy
@@ -1095,6 +1095,15 @@ if (onnxruntime_USE_CUDA)
10951095
)
10961096
endif()
10971097

1098+
if (onnxruntime_USE_CUDA AND onnxruntime_BUILD_CUDA_EP_AS_PLUGIN)
1099+
add_custom_command(
1100+
TARGET onnxruntime_pybind11_state POST_BUILD
1101+
COMMAND ${CMAKE_COMMAND} -E copy
1102+
$<TARGET_FILE:onnxruntime_providers_cuda_plugin>
1103+
$<TARGET_FILE_DIR:${build_output_target}>/onnxruntime/capi/
1104+
)
1105+
endif()
1106+
10981107
if (onnxruntime_USE_CANN)
10991108
add_custom_command(
11001109
TARGET onnxruntime_pybind11_state POST_BUILD

0 commit comments

Comments
 (0)