未验证 提交 741ce8bb 编写于 作者: T Tao Luo 提交者: GitHub

inference_shared_library support profile (#16275)

test=develop
上级 17d62ab2
...@@ -4,6 +4,9 @@ option(WITH_MKL "Compile demo with MKL/OpenBlas support, default use MKL. ...@@ -4,6 +4,9 @@ option(WITH_MKL "Compile demo with MKL/OpenBlas support, default use MKL.
option(WITH_GPU "Compile demo with GPU/CPU, default use CPU." OFF) option(WITH_GPU "Compile demo with GPU/CPU, default use CPU." OFF)
option(WITH_STATIC_LIB "Compile demo with static/shared library, default use static." ON) option(WITH_STATIC_LIB "Compile demo with static/shared library, default use static." ON)
option(USE_TENSORRT "Compile demo with TensorRT." OFF) option(USE_TENSORRT "Compile demo with TensorRT." OFF)
if(NOT WITH_STATIC_LIB)
add_definitions("-DPADDLE_WITH_SHARED_LIB")
endif()
macro(safe_set_static_flag) macro(safe_set_static_flag)
foreach(flag_var foreach(flag_var
......
...@@ -30,6 +30,9 @@ DEFINE_string( ...@@ -30,6 +30,9 @@ DEFINE_string(
"path of data; each line is a record, format is " "path of data; each line is a record, format is "
"'<space splitted floats as data>\t<space splitted ints as shape'"); "'<space splitted floats as data>\t<space splitted ints as shape'");
DEFINE_bool(use_gpu, false, "Whether use gpu."); DEFINE_bool(use_gpu, false, "Whether use gpu.");
#ifdef PADDLE_WITH_SHARED_LIB
DEFINE_bool(profile, false, "Whether use profile.");
#endif
namespace paddle { namespace paddle {
namespace demo { namespace demo {
......
{ {
global: global:
*paddle*; *paddle*;
*Pass*; *Pass*;
*profile*;
local: local:
*; *;
}; };
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册