From dc6f9a07d2d26e4438934aea2b0ce0172b981ec6 Mon Sep 17 00:00:00 2001 From: Aditya Rastogi Date: Tue, 22 Jul 2025 11:27:37 -0700 Subject: [PATCH 1/3] Use macros for model compat APIs --- .../onnxruntime/core/session/onnxruntime_ep_c_api.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h index dc9c24501c4df..df4aa5fe7fa5c 100644 --- a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h +++ b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h @@ -695,8 +695,8 @@ struct OrtEp { * * \since Version 1.23. */ - const char*(ORT_API_CALL* GetCompiledModelCompatibilityInfo)(_In_ OrtEp* this_ptr, - _In_ const OrtGraph* graph); + ORT_API_T(const char*, GetCompiledModelCompatibilityInfo, _In_ OrtEp* this_ptr, + _In_ const OrtGraph* graph); }; /** \brief The function signature that ORT will call to create OrtEpFactory instances. @@ -873,9 +873,9 @@ struct OrtEpFactory { * * \since Version 1.23. */ - OrtStatus*(ORT_API_CALL* ValidateCompiledModelCompatibilityInfo)(_In_ OrtEpFactory* this_ptr, - _In_ const char* compatibility_info, - _Out_ OrtCompiledModelCompatibility* model_compatibility); + ORT_API2_STATUS(ValidateCompiledModelCompatibilityInfo, _In_ OrtEpFactory* this_ptr, + _In_ const char* compatibility_info, + _Out_ OrtCompiledModelCompatibility* model_compatibility); /** \brief Create an OrtAllocator that can be shared across sessions for the given OrtMemoryInfo. * From fbc109a052ab578297571cfdc19d33588538d52f Mon Sep 17 00:00:00 2001 From: adrastogi Date: Tue, 22 Jul 2025 13:27:09 -0700 Subject: [PATCH 2/3] Update include/onnxruntime/core/session/onnxruntime_ep_c_api.h Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- include/onnxruntime/core/session/onnxruntime_ep_c_api.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h index df4aa5fe7fa5c..12a2949643386 100644 --- a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h +++ b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h @@ -696,7 +696,7 @@ struct OrtEp { * \since Version 1.23. */ ORT_API_T(const char*, GetCompiledModelCompatibilityInfo, _In_ OrtEp* this_ptr, - _In_ const OrtGraph* graph); + _In_ const OrtGraph* graph); }; /** \brief The function signature that ORT will call to create OrtEpFactory instances. From c44bf5059036649d1ca8b28dabaf8c1489e1f22b Mon Sep 17 00:00:00 2001 From: adrastogi Date: Tue, 22 Jul 2025 13:27:16 -0700 Subject: [PATCH 3/3] Update include/onnxruntime/core/session/onnxruntime_ep_c_api.h Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- include/onnxruntime/core/session/onnxruntime_ep_c_api.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h index 12a2949643386..f7e304c98d7b5 100644 --- a/include/onnxruntime/core/session/onnxruntime_ep_c_api.h +++ b/include/onnxruntime/core/session/onnxruntime_ep_c_api.h @@ -874,8 +874,8 @@ struct OrtEpFactory { * \since Version 1.23. */ ORT_API2_STATUS(ValidateCompiledModelCompatibilityInfo, _In_ OrtEpFactory* this_ptr, - _In_ const char* compatibility_info, - _Out_ OrtCompiledModelCompatibility* model_compatibility); + _In_ const char* compatibility_info, + _Out_ OrtCompiledModelCompatibility* model_compatibility); /** \brief Create an OrtAllocator that can be shared across sessions for the given OrtMemoryInfo. *