Skip to content

Conversation

edgchen1
Copy link
Contributor

@edgchen1 edgchen1 commented Aug 7, 2025

Description

Move provider-specific unit tests that were formerly in onnxruntime_test_all to a new test program, onnxruntime_provider_test. Notably, this includes the op tests which test different provider implementations.

Enable some tests in onnxruntime_provider_test (those using ModelTester or OpTester) to use a plugin EP. The plugin EP usage is specified at runtime, so it is referred to as "dynamic". The dynamic plugin EP configuration can be specified with environment variable ORT_UNIT_TEST_MAIN_DYNAMIC_PLUGIN_EP_CONFIG_JSON.

This is an example value for ORT_UNIT_TEST_MAIN_DYNAMIC_PLUGIN_EP_CONFIG_JSON. The test infrastructure will register the plugin EP library at path/to/example_plugin_ep.dll. The op tests will use a plugin EP instance with the name example_ep.

{
  "ep_library_registration_name": "example_ep",
  "ep_library_path": "path/to/example_plugin_ep.dll",
  "selected_ep_name": "example_ep"
}

Motivation and Context

Enable use of plugin EPs in some provider-specific unit tests.

Notes for Reviewers

  • There are many modified files but most of the changes are just #include path updates.
  • I suggest setting the diff view to ignore whitespace changes.

edgchen1 added 30 commits July 31, 2025 12:48
…viderFactoryForEpDevices() to new helper AddEpOptionsToSessionOptions()
…out a symbol not being found for OrtDevice::CPU. go figure.
@edgchen1 edgchen1 marked this pull request as ready for review September 12, 2025 01:36
@edgchen1 edgchen1 changed the title [WIP] Move provider tests to onnxruntime_provider_test and enable use of plugin EPs Move provider tests to onnxruntime_provider_test and enable use of plugin EPs Sep 12, 2025
@edgchen1 edgchen1 merged commit 1c9a388 into main Sep 15, 2025
89 of 92 checks passed
@edgchen1 edgchen1 deleted the edgchen1/plugin_ep_unit_tests branch September 15, 2025 22:11
@TedThemistokleous
Copy link
Contributor

Hey , just seeing this now @edgchen1 @snnn.

The MIGraphX was using the pai_test_launcher.sh script in our CI so this has caused a build break for MIGraphX. We typically sync weekly to your Mainline and build against Onnxruntime to ensure MIGraphX EP builds off your main won't cause breaks. |

Is there something else we should be using now here instead? Should we just run the test launcher directly? From what I can tell, it seems like the Onnxruntime_test_all binary still exists I think we just need to add a filter for excluded tests still?

Is there a larger change here for builds/testing that we need to incorporate in our infrastructure? If so please let me know

@edgchen1
Copy link
Contributor Author

Hey , just seeing this now @edgchen1 @snnn.

The MIGraphX was using the pai_test_launcher.sh script in our CI so this has caused a build break for MIGraphX. We typically sync weekly to your Mainline and build against Onnxruntime to ensure MIGraphX EP builds off your main won't cause breaks. |

Is there something else we should be using now here instead? Should we just run the test launcher directly? From what I can tell, it seems like the Onnxruntime_test_all binary still exists I think we just need to add a filter for excluded tests still?

Is there a larger change here for builds/testing that we need to incorporate in our infrastructure? If so please let me know

Sorry. I didn't find any existing usages in the repo, so I assumed it was fine to delete. You can add it back if you want.

The main change is to move some tests from onnxruntime_test_all to a new test program, onnxruntime_provider_test. To get the same test coverage, you'd want to also run the new test program. You may need to adjust your test filters accordingly, e.g., if they match a test that got moved.

@TedThemistokleous
Copy link
Contributor

Good to know. Sure I can add that back in but if I can just call in the same piece, I can adjust CI directly then if this is the case.

@TedThemistokleous
Copy link
Contributor

I think this was used when there was MIGraphX EP/ROCm EP CI but that got removed recently and we're in the process of adding it back

adrianlizarraga added a commit that referenced this pull request Sep 24, 2025
### Description
Cherry-pick the following PRs into the ORT 1.23.1 branch:

- Fix Attention GQA implementation on CPU
- **MANUAL MERGE**: see
#26057
  - main merge date: Sept 15, 11:33am
  - pr: #25966
  - commit: d530b29
- Address edge GetMemInfo edge cases
  - main merge date: Sept 16, 10:32am
  - pr: #26021
  - commit: d251f3a
- Implement new Python APIs
  - main merge date: Sept 17, 11:44am
  - pr: #25999
  - commit: abc63e8
- MemcpyFromHost and MemcpyToHost support for plugin EPs
- **MERGE CONFLICT** on file
onnxruntime/test/optimizer/transpose_optimizer_test.cc. Conflicts with
#25689
  - main merge date: Sept 23, 10:42am
  - pr: #26088
  - commit: 4545732
- [TRT RTX EP] Fix bug for generating the correct subgraph in
GetCapability #26132
  - main merge date: Sept 23, 8:54pm
  - pr: #26132
  - commit: 72e56e7


### Motivation and Context
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->

---------

Co-authored-by: Dmitri Smirnov <[email protected]>
Co-authored-by: Edward Chen <[email protected]>
Co-authored-by: Chi Lo <[email protected]>
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