TensorRT 10.16.1
nvinfer2::safe::ISafePluginResourceContext Class Referenceabstract

Interface for plugins to access per context resources provided by TensorRT. More...

#include <NvInferSafePlugin.h>

Public Member Functions

virtual ISafeMemAllocatorgetSafeMemAllocator () const noexcept=0
 Get the GPU allocator associated with the resource context. More...
 
virtual ISafeRecordergetSafeRecorder () const noexcept=0
 Get the error recorder associated with the resource context. More...
 
virtual RuntimeErrorInformationgetRuntimeErrorInformation () const noexcept=0
 Get the RuntimeErrorInformation associated with the resource context. More...
 
virtual ~ISafePluginResourceContext () noexcept=default
 

Protected Member Functions

 ISafePluginResourceContext ()=default
 
 ISafePluginResourceContext (ISafePluginResourceContext const &)=default
 
 ISafePluginResourceContext (ISafePluginResourceContext &&)=default
 
ISafePluginResourceContextoperator= (ISafePluginResourceContext const &) &=default
 
ISafePluginResourceContextoperator= (ISafePluginResourceContext &&) &=default
 

Detailed Description

Interface for plugins to access per context resources provided by TensorRT.

There is no public way to construct an ISafePluginResourceContext (i.e. User should not construct this object). It appears as an argument to IPluginV3OneSafeRuntime::initResource(). Overrides of that method can use the ISafePluginResourceContext object to access the ISafeMemAllocator and ISafeRecorder object asscociate with the specific TRTGraph that the plugin is part of

Warning
Do not inherit from this class, as doing so will break forward-compatibility of the API and ABI.
See also
IPluginV3OneSafeRuntime::initResource()

Constructor & Destructor Documentation

◆ ~ISafePluginResourceContext()

virtual nvinfer2::safe::ISafePluginResourceContext::~ISafePluginResourceContext ( )
virtualdefaultnoexcept

◆ ISafePluginResourceContext() [1/3]

nvinfer2::safe::ISafePluginResourceContext::ISafePluginResourceContext ( )
protecteddefault

◆ ISafePluginResourceContext() [2/3]

nvinfer2::safe::ISafePluginResourceContext::ISafePluginResourceContext ( ISafePluginResourceContext const &  )
protecteddefault

◆ ISafePluginResourceContext() [3/3]

nvinfer2::safe::ISafePluginResourceContext::ISafePluginResourceContext ( ISafePluginResourceContext &&  )
protecteddefault

Member Function Documentation

◆ getRuntimeErrorInformation()

virtual RuntimeErrorInformation * nvinfer2::safe::ISafePluginResourceContext::getRuntimeErrorInformation ( ) const
pure virtualnoexcept

Get the RuntimeErrorInformation associated with the resource context.

Precondition
RUNTIME API
See also
IPluginV3OneSafeRuntime::initResource()

◆ getSafeMemAllocator()

virtual ISafeMemAllocator * nvinfer2::safe::ISafePluginResourceContext::getSafeMemAllocator ( ) const
pure virtualnoexcept

Get the GPU allocator associated with the resource context.

Precondition
INIT API
See also
IPluginV3OneSafeRuntime::initResource()

◆ getSafeRecorder()

virtual ISafeRecorder * nvinfer2::safe::ISafePluginResourceContext::getSafeRecorder ( ) const
pure virtualnoexcept

Get the error recorder associated with the resource context.

Precondition
RUNTIME API
See also
IPluginV3OneSafeRuntime::initResource()

◆ operator=() [1/2]

ISafePluginResourceContext & nvinfer2::safe::ISafePluginResourceContext::operator= ( ISafePluginResourceContext &&  ) &
protecteddefault

◆ operator=() [2/2]

ISafePluginResourceContext & nvinfer2::safe::ISafePluginResourceContext::operator= ( ISafePluginResourceContext const &  ) &
protecteddefault

The documentation for this class was generated from the following file:

  Copyright © 2024 NVIDIA Corporation
  Privacy Policy | Manage My Privacy | Do Not Sell or Share My Data | Terms of Service | Accessibility | Corporate Policies | Product Security | Contact