@@ -16,21 +16,21 @@ namespace nvinfer1
1616 {
1717 }
1818
19- void DecodePlugin::serialize (void * buffer) const
19+ void DecodePlugin::serialize (void * buffer) const TRT_NOEXCEPT
2020 {
2121 }
2222
23- size_t DecodePlugin::getSerializationSize () const
24- {
23+ size_t DecodePlugin::getSerializationSize () const TRT_NOEXCEPT
24+ {
2525 return 0 ;
2626 }
2727
28- int DecodePlugin::initialize ()
28+ int DecodePlugin::initialize () TRT_NOEXCEPT
2929 {
3030 return 0 ;
3131 }
3232
33- Dims DecodePlugin::getOutputDimensions (int index, const Dims* inputs, int nbInputDims)
33+ Dims DecodePlugin::getOutputDimensions (int index, const Dims* inputs, int nbInputDims) TRT_NOEXCEPT
3434 {
3535 // output the result to channel
3636 int totalCount = 0 ;
@@ -42,63 +42,63 @@ namespace nvinfer1
4242 }
4343
4444 // Set plugin namespace
45- void DecodePlugin::setPluginNamespace (const char * pluginNamespace)
45+ void DecodePlugin::setPluginNamespace (const char * pluginNamespace) TRT_NOEXCEPT
4646 {
4747 mPluginNamespace = pluginNamespace;
4848 }
4949
50- const char * DecodePlugin::getPluginNamespace () const
50+ const char * DecodePlugin::getPluginNamespace () const TRT_NOEXCEPT
5151 {
5252 return mPluginNamespace ;
5353 }
5454
5555 // Return the DataType of the plugin output at the requested index
56- DataType DecodePlugin::getOutputDataType (int index, const nvinfer1::DataType* inputTypes, int nbInputs) const
56+ DataType DecodePlugin::getOutputDataType (int index, const nvinfer1::DataType* inputTypes, int nbInputs) const TRT_NOEXCEPT
5757 {
5858 return DataType::kFLOAT ;
5959 }
6060
6161 // Return true if output tensor is broadcast across a batch.
62- bool DecodePlugin::isOutputBroadcastAcrossBatch (int outputIndex, const bool * inputIsBroadcasted, int nbInputs) const
62+ bool DecodePlugin::isOutputBroadcastAcrossBatch (int outputIndex, const bool * inputIsBroadcasted, int nbInputs) const TRT_NOEXCEPT
6363 {
6464 return false ;
6565 }
6666
6767 // Return true if plugin can use input that is broadcast across batch without replication.
68- bool DecodePlugin::canBroadcastInputAcrossBatch (int inputIndex) const
68+ bool DecodePlugin::canBroadcastInputAcrossBatch (int inputIndex) const TRT_NOEXCEPT
6969 {
7070 return false ;
7171 }
7272
73- void DecodePlugin::configurePlugin (const PluginTensorDesc* in, int nbInput, const PluginTensorDesc* out, int nbOutput)
73+ void DecodePlugin::configurePlugin (const PluginTensorDesc* in, int nbInput, const PluginTensorDesc* out, int nbOutput) TRT_NOEXCEPT
7474 {
7575 }
7676
7777 // Attach the plugin object to an execution context and grant the plugin the access to some context resource.
78- void DecodePlugin::attachToContext (cudnnContext* cudnnContext, cublasContext* cublasContext, IGpuAllocator* gpuAllocator)
78+ void DecodePlugin::attachToContext (cudnnContext* cudnnContext, cublasContext* cublasContext, IGpuAllocator* gpuAllocator) TRT_NOEXCEPT
7979 {
8080 }
8181
8282 // Detach the plugin object from its execution context.
83- void DecodePlugin::detachFromContext () {}
83+ void DecodePlugin::detachFromContext () TRT_NOEXCEPT {}
8484
85- const char * DecodePlugin::getPluginType () const
85+ const char * DecodePlugin::getPluginType () const TRT_NOEXCEPT
8686 {
8787 return " Decode_TRT" ;
8888 }
8989
90- const char * DecodePlugin::getPluginVersion () const
90+ const char * DecodePlugin::getPluginVersion () const TRT_NOEXCEPT
9191 {
9292 return " 1" ;
9393 }
9494
95- void DecodePlugin::destroy ()
95+ void DecodePlugin::destroy () TRT_NOEXCEPT
9696 {
9797 delete this ;
9898 }
9999
100100 // Clone the plugin
101- IPluginV2IOExt* DecodePlugin::clone () const
101+ IPluginV2IOExt* DecodePlugin::clone () const TRT_NOEXCEPT
102102 {
103103 DecodePlugin *p = new DecodePlugin ();
104104 p->setPluginNamespace (mPluginNamespace );
@@ -190,7 +190,7 @@ namespace nvinfer1
190190 }
191191 }
192192
193- int DecodePlugin::enqueue (int batchSize, const void *const * inputs, void ** outputs, void * workspace, cudaStream_t stream)
193+ int DecodePlugin::enqueue (int batchSize, const void *const * inputs, void *TRT_CONST_ENQUEUE * outputs, void * workspace, cudaStream_t stream) TRT_NOEXCEPT
194194 {
195195 // GPU
196196 // CUDA_CHECK(cudaStreamSynchronize(stream));
@@ -209,29 +209,29 @@ namespace nvinfer1
209209 mFC .fields = mPluginAttributes .data ();
210210 }
211211
212- const char * DecodePluginCreator::getPluginName () const
212+ const char * DecodePluginCreator::getPluginName () const TRT_NOEXCEPT
213213 {
214214 return " Decode_TRT" ;
215215 }
216216
217- const char * DecodePluginCreator::getPluginVersion () const
217+ const char * DecodePluginCreator::getPluginVersion () const TRT_NOEXCEPT
218218 {
219219 return " 1" ;
220220 }
221221
222- const PluginFieldCollection* DecodePluginCreator::getFieldNames ()
222+ const PluginFieldCollection* DecodePluginCreator::getFieldNames () TRT_NOEXCEPT
223223 {
224224 return &mFC ;
225225 }
226226
227- IPluginV2IOExt* DecodePluginCreator::createPlugin (const char * name, const PluginFieldCollection* fc)
227+ IPluginV2IOExt* DecodePluginCreator::createPlugin (const char * name, const PluginFieldCollection* fc) TRT_NOEXCEPT
228228 {
229229 DecodePlugin* obj = new DecodePlugin ();
230230 obj->setPluginNamespace (mNamespace .c_str ());
231231 return obj;
232232 }
233233
234- IPluginV2IOExt* DecodePluginCreator::deserializePlugin (const char * name, const void * serialData, size_t serialLength)
234+ IPluginV2IOExt* DecodePluginCreator::deserializePlugin (const char * name, const void * serialData, size_t serialLength) TRT_NOEXCEPT
235235 {
236236 // This object will be deleted when the network is destroyed, which will
237237 // call PReluPlugin::destroy()
0 commit comments