From 43ec22712c9a257fe0eb41010699a4f288697d61 Mon Sep 17 00:00:00 2001 From: Wilber Date: Fri, 13 Jan 2023 11:27:22 +0800 Subject: [PATCH] [Inference] Update exported symbols. (#47538) --- paddle/fluid/inference/paddle_inference.map | 71 ++++++++++++++++++- .../paddle_inference_custom_device.map | 71 ++++++++++++++++++- 2 files changed, 140 insertions(+), 2 deletions(-) diff --git a/paddle/fluid/inference/paddle_inference.map b/paddle/fluid/inference/paddle_inference.map index 0d2b0d659b3..acbdcf5d783 100644 --- a/paddle/fluid/inference/paddle_inference.map +++ b/paddle/fluid/inference/paddle_inference.map @@ -1,6 +1,75 @@ { global: - *paddle*; + extern "C++" { + *paddle_infer::GetVersion*; + *paddle_infer::UpdateDllFlag*; + *paddle_infer::experimental::InternalUtils*; + *paddle_infer::Tensor*; + *paddle_infer::Predictor*; + *paddle_infer::CreatePredictor*; + *paddle_infer::GetTrtCompileVersion*; + *paddle_infer::GetTrtRuntimeVersion*; + *paddle_infer::GetNumBytesOfDataType*; + *paddle_infer::ConvertToMixedPrecision*; + *paddle_infer::contrib::TensorUtils*; + *paddle_infer::contrib::Status*; + *paddle_infer::services::PredictorPool*; + *paddle_infer::LayoutConvert*; + + *paddle::experimental*; + *paddle::internal*; + *paddle::get_version*; + *paddle::LiteNNAdapterConfig*; + *paddle::AnalysisConfig::*; + *paddle::PaddlePredictor::*; + *paddle::CreatePaddlePredictor*; + *paddle::NativePaddlePredictor*; + *paddle::AnalysisPredictor*; + *paddle::PaddleDtypeSize*; + *paddle::ZeroCopyTensor*; + *paddle::*Strategy*; + *paddle::NativeConfig*; + *paddle::PaddleBuf*; + *paddle::PaddleTensor*; + *paddle::UpdateDllFlag*; + *paddle::MakeCipher*; + *paddle::DistConfig*; + *paddle::DefaultGPUPlace*; + *paddle::ResourceManager*; + *paddle::GPUContextResource*; + *paddle::CPUContextResource*; + + *paddle::LoadCustomOperatorLib*; + *paddle::RegisterAllCustomOperator*; + + /* ut needs the following symbol, we need to modify all the ut to hidden such symbols */ + + /* Another question: the ut size will grow from 50M to 80M, why? */ + + *paddle::detail*; + *paddle::imperative*; + *paddle::detailv3*; + *paddle::memory*; + *paddle::string*; + *paddle::operators*; + + *paddle::distributed*; + /* *paddle::distributed::FleetWrapper*; */ + /* *paddle::distributed::TensorTable*; */ + /* *paddle::distributed::TableManager*; */ + + /* *paddle::inference*; */ + *paddle::inference::ReadBinaryFile*; + + *paddle::platform*; + /* *paddle::platform::GetExportedFlagInfoMap*; */ + + /* *paddle::framework*; */ + *paddle::framework::InterpreterCore*; + *paddle::framework::Executor*; + }; + + /* The following symbols need to reconsider. */ *Pass*; *profile*; *phi*; diff --git a/paddle/fluid/inference/paddle_inference_custom_device.map b/paddle/fluid/inference/paddle_inference_custom_device.map index 391842a4c61..83de7d9a775 100644 --- a/paddle/fluid/inference/paddle_inference_custom_device.map +++ b/paddle/fluid/inference/paddle_inference_custom_device.map @@ -1,6 +1,75 @@ { global: - *paddle*; + extern "C++" { + *paddle_infer::GetVersion*; + *paddle_infer::UpdateDllFlag*; + *paddle_infer::experimental::InternalUtils*; + *paddle_infer::Tensor*; + *paddle_infer::Predictor*; + *paddle_infer::CreatePredictor*; + *paddle_infer::GetTrtCompileVersion*; + *paddle_infer::GetTrtRuntimeVersion*; + *paddle_infer::GetNumBytesOfDataType*; + *paddle_infer::ConvertToMixedPrecision*; + *paddle_infer::contrib::TensorUtils*; + *paddle_infer::contrib::Status*; + *paddle_infer::services::PredictorPool*; + *paddle_infer::LayoutConvert*; + + *paddle::experimental*; + *paddle::internal*; + *paddle::get_version*; + *paddle::LiteNNAdapterConfig*; + *paddle::AnalysisConfig::*; + *paddle::PaddlePredictor::*; + *paddle::CreatePaddlePredictor*; + *paddle::NativePaddlePredictor*; + *paddle::AnalysisPredictor*; + *paddle::PaddleDtypeSize*; + *paddle::ZeroCopyTensor*; + *paddle::*Strategy*; + *paddle::NativeConfig*; + *paddle::PaddleBuf*; + *paddle::PaddleTensor*; + *paddle::UpdateDllFlag*; + *paddle::MakeCipher*; + *paddle::DistConfig*; + *paddle::DefaultGPUPlace*; + *paddle::ResourceManager*; + *paddle::GPUContextResource*; + *paddle::CPUContextResource*; + + *paddle::LoadCustomOperatorLib*; + *paddle::RegisterAllCustomOperator*; + + /* ut needs the following symbol, we need to modify all the ut to hidden such symbols */ + + /* Another question: the ut size will grow from 50M to 80M, why? */ + + *paddle::detail*; + *paddle::imperative*; + *paddle::detailv3*; + *paddle::memory*; + *paddle::string*; + *paddle::operators*; + + *paddle::distributed*; + /* *paddle::distributed::FleetWrapper*; */ + /* *paddle::distributed::TensorTable*; */ + /* *paddle::distributed::TableManager*; */ + + /* *paddle::inference*; */ + *paddle::inference::ReadBinaryFile*; + + *paddle::platform*; + /* *paddle::platform::GetExportedFlagInfoMap*; */ + + /* *paddle::framework*; */ + *paddle::framework::InterpreterCore*; + *paddle::framework::Executor*; + }; + + /* The following symbols need to reconsider. */ *Pass*; *profile*; *phi*; -- GitLab