openvino
a640903f - Fixed webnn test crash issue (#34708) (#34831)

Commit
41 days ago
Fixed webnn test crash issue (#34708) (#34831) ### Details: - In the debugger, I found the `read_to` located at `openvino.dll`. All other plugin call the `read_to` method to construct a string will allocate the memory in `openvino.dll` - The `onnxruntime_providers_openvino_plugin_impl.dll`'s new feature will convert `float` map to `std::string`. The `float` map `Any` object was created at `openvino_intel_npu_plugin.dll`. So the `_impl` in `Any` is `openvino_intel_npu_plugin`'s type. `_temp` is `onnxruntime_providers_openvino_plugin_impl`'s `string` type. Then the `Any`'s dtor will call the `onnxruntime_providers_openvino_plugin_impl`'s `string` dtor. That caused the memory issue. ### Solution: - Create a virtual method `read_from` and let the copy call the real type's method. In this way, it can call the `onnxruntime_providers_openvino_plugin_impl`'s ctor and dtor. - Port https://github.com/openvinotoolkit/openvino/pull/34708 ### Tickets: - [CVS-182610](https://jira.devtools.intel.com/browse/CVS-182610) ### AI Assistance: - *AI assistance used: no / yes* - *If yes, summarize how AI was used and what human validation was performed (build/tests/manual checks).* Co-authored-by: Pawel Raasz <pawel.raasz@intel.com>
Author
Parents
Loading