Skip to content

Guard removed APIs in TRT 11#28611

Open
kevinch-nv wants to merge 1 commit into
microsoft:mainfrom
kevinch-nv:remove-old-apis-trt-11
Open

Guard removed APIs in TRT 11#28611
kevinch-nv wants to merge 1 commit into
microsoft:mainfrom
kevinch-nv:remove-old-apis-trt-11

Conversation

@kevinch-nv
Copy link
Copy Markdown
Contributor

Description

TRT 11.0 removes many deprecated APIs, so guard TRT-EP code accordingly to support TRT 11 builds.

Motivation and Context

Fixes compilation with TRT 11.0

@chilo-ms
Copy link
Copy Markdown
Contributor

please run lintrunner -a to format the files.

Signed-off-by: Kevin Chen <kevinch@nvidia.com>
@kevinch-nv kevinch-nv force-pushed the remove-old-apis-trt-11 branch from 089cb09 to fcb8975 Compare May 21, 2026 18:05
#pragma warning(disable : 4996)
#endif
size_t mem_size = trt_engine->getDeviceMemorySize();
size_t mem_size = trt_engine->getDeviceMemorySizeV2();
Copy link
Copy Markdown
Contributor

@chilo-ms chilo-ms May 21, 2026

Choose a reason for hiding this comment

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

Does this API call needs to be guarded as well? as current TRT EP still supports building with older TRT, e.g. TRT 8. We might consider remove the support for TRT 8 though.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I'm OK with removing support for TRT 8

Copy link
Copy Markdown
Contributor

@chilo-ms chilo-ms May 21, 2026

Choose a reason for hiding this comment

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

For this PR let's still keep the support for TRT 8 for now as there might be some customers using TRT 8 and we should notice them before we really remove the support.
So i think we should put guard on getDeviceMemorySizeV2 here for TRT >= 10?

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.

2 participants