Fix missing registration for new dml device selection API (#17898)

Fix missing registration for new dml device selection API

Co-authored-by: Sheil Kumar <sheilk@microsoft.com>
This commit is contained in:
Sheil Kumar 2023-10-12 09:41:45 -07:00 committed by GitHub
parent fa0a79a921
commit 2efab54f9c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -514,7 +514,7 @@ ORT_API_STATUS_IMPL(FreeGPUAllocation, _In_ void* ptr) {
API_IMPL_END
}
ORT_API_STATUS_IMPL(SessionOptionsAppendExecutionProvider_DML2, _In_ OrtSessionOptions* options, OrtDmlDeviceOptions* device_options) {
ORT_API_STATUS_IMPL(OrtSessionOptionsAppendExecutionProvider_DML2, _In_ OrtSessionOptions* options, OrtDmlDeviceOptions* device_options) {
API_IMPL_BEGIN
#ifdef USE_DML
auto factory = onnxruntime::DMLProviderFactoryCreator::CreateFromOptions(device_options);
@ -547,7 +547,8 @@ static constexpr OrtDmlApi ort_dml_api_10_to_x = {
&OrtSessionOptionsAppendExecutionProviderEx_DML,
&CreateGPUAllocationFromD3DResource,
&FreeGPUAllocation,
&GetD3D12ResourceFromAllocation
&GetD3D12ResourceFromAllocation,
&OrtSessionOptionsAppendExecutionProvider_DML2,
};
const OrtDmlApi* GetOrtDmlApi(_In_ uint32_t /*version*/) NO_EXCEPTION {