-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[TRT-EP] Ignore deprecated warnings for TRT APIs #25105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds MSVC-specific pragmas to suppress deprecation warnings (C4996) for TensorRT’s weakly-typed APIs on Windows builds.
- Wraps key code sections with
#pragma warning(push/disable:4996)
and#pragma warning(pop)
under_MSC_VER
- Targets layer normalization fallback, precision flag setting, and INT8 configuration blocks
Comments suppressed due to low confidence (1)
onnxruntime/core/providers/tensorrt/tensorrt_execution_provider.cc:2972
- [nitpick] Add a brief comment here (and at other pragma blocks) to explain which deprecated TensorRT APIs trigger warning C4996, so future maintainers understand the rationale for silencing it.
#if defined(_MSC_VER)
Signed-off-by: Kevin Chen <kevinch@nvidia.com>
/azp run Linux QNN CI Pipeline,Win_TRT_Minimal_CUDA_Test_CI,Windows ARM64 QNN CI Pipeline,Windows GPU Doc Gen CI Pipeline,Windows x64 QNN CI Pipeline |
Azure Pipelines successfully started running 5 pipeline(s). |
please help address format issue |
Fixed. Do I need to fix the co-pilot suggestion as well? |
Signed-off-by: Kevin Chen <kevinch@nvidia.com>
@chilo-ms can you help run CI again? |
/azp run Linux QNN CI Pipeline,Win_TRT_Minimal_CUDA_Test_CI,Windows ARM64 QNN CI Pipeline,Windows GPU Doc Gen CI Pipeline,Windows x64 QNN CI Pipeline |
Azure Pipelines successfully started running 5 pipeline(s). |
Description
In TensorRT 10.12, weakly-typed network and related APIs have been marked deprecated. Ignore these deprecated API warnings for the Windows build.