Skip to content

Conversation

@adrianlizarraga
Copy link
Contributor

Description

Updates the BaseTester class used by the onnxruntime_provider_test tool to support plugin EPs that use a kernel registry but compile other nodes. For example, TRT EP only uses registered kernels for Memcpy* nodes, but compiles every other node.

Without this change, plugin EPs that use a mix of compiled nodes and registered kernels cannot be tested with onnxruntime_provider_test.

Motivation and Context

@adrianlizarraga adrianlizarraga changed the title BaseTester: support plugin EPs with a compiled nodes and registered kernels BaseTester: support plugin EPs with compiled nodes and registered kernels Jan 27, 2026
const auto& provider_type = ep.Type();

constexpr std::array kEpsThatDoNotUseKernelRegistry{
constexpr std::array kEpsThatDoNotUseKernelRegistryForAllNodes{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe call them "EPs that compile nodes" instead of "EPs that do not use kernel registry for all nodes"

constexpr std::array kEpsThatDoNotUseKernelRegistryForAllNodes{
kOpenVINOExecutionProvider,
kTensorrtExecutionProvider,
kTensorrtExecutionProvider, // uses kernel registry for Memcpy* nodes, but compiles all others.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just to confirm, the plugin EP name will be different, right? that assumption is made here:

ORT_ENFORCE(std::find(all_provider_types.begin(), all_provider_types.end(),
*dynamic_plugin_ep_name) == all_provider_types.end(),
"Dynamic plugin EP name conflicts with a known EP name: ", *dynamic_plugin_ep_name);

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question. @chilo-ms do you know if the plugin EP name is different?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume so, but let me confirm with Nvidia for their plugin TRT RTX EP.

Also, do we want to include provider-bridge TRT RTX EP, kNvTensorRTRTXExecutionProvider, in this list as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should only add kNvTensorRTRTXExecutionProvider to this list if its name differs from the plugin EP version, right?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should only add kNvTensorRTRTXExecutionProvider to this list if its name differs from the plugin EP version, right?

Yes, waiting for Nvidia's reply for the name of their plugin TRT RTX EP, will update.

Copy link
Contributor

@chilo-ms chilo-ms Jan 29, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ishwar-raut1 as you mentioned offline, the name to register EP DLL is also set for plugin TRT RTX EP name. Could you help confirm that the EP name doesn't conflict with “TensorRTExecutionProvier” and "NvTensorRTRTXExecutionProvier” (will be added) in the kEpsThatCompileNodes list?

@keshavv27 @gedoensmax

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The name to register the EP DLL is also set for the plugin TRT RTX EP name. if the same is used to register the dll then there could be a conflict.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To run onnxruntime_provider_test with plugin TRT RTX EP, the plugin EP name must not conflict with NvTensorRTRTXExecutionProvider; otherwise, the test will fail at this check that Ed mentioned:

ORT_ENFORCE(std::find(all_provider_types.begin(), all_provider_types.end(),
*dynamic_plugin_ep_name) == all_provider_types.end(),
"Dynamic plugin EP name conflicts with a known EP name: ", *dynamic_plugin_ep_name);

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can conditionally add NvTensorRTRTXExecutionProvider to all_provider_types only if USE_NV is defined, which occurs only when the provider-bridge NV TRT RTX EP is built with ORT.

The result would be that this error would only occur if the user tried to use both the provider-bridge and plugin EPs at the same time (with a build that included the provide-bridge EP).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants