From e508460d9b16c3dd643476fa85ff045ee7a08df9 Mon Sep 17 00:00:00 2001 From: phlrain Date: Fri, 11 Jun 2021 06:46:45 +0000 Subject: [PATCH] add new test --- paddle/fluid/framework/CMakeLists.txt | 2 +- paddle/fluid/framework/new_exec_test.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/paddle/fluid/framework/CMakeLists.txt b/paddle/fluid/framework/CMakeLists.txt index bd36d660be..d1193bbc8f 100644 --- a/paddle/fluid/framework/CMakeLists.txt +++ b/paddle/fluid/framework/CMakeLists.txt @@ -409,7 +409,7 @@ cc_library(custom_operator SRCS custom_operator.cc DEPS tensor attribute framewo cc_test(custom_tensor_test SRCS custom_tensor_test.cc DEPS custom_tensor glog) #cc_binary(test_executor SRCS test_executor.cc DEPS executor op_registry ${GLOB_OP_LIB} ${GLOB_OPERATOR_DEPS} ) -#cc_binary(new_executor SRCS new_exec_test.cc DEPS operator op_registry executor ${GLOB_OP_LIB} ${GLOB_OPERATOR_DEPS} profiler) +cc_binary(new_executor SRCS new_exec_test.cc DEPS operator op_registry executor ${GLOB_OP_LIB} ${GLOB_OPERATOR_DEPS} profiler) set(FLUID_FRAMEWORK_MODULES proto_desc memory lod_tensor executor data_feed_proto layer dynamic_loader custom_operator) diff --git a/paddle/fluid/framework/new_exec_test.cc b/paddle/fluid/framework/new_exec_test.cc index c8a28c3a6d..5a352e00ed 100644 --- a/paddle/fluid/framework/new_exec_test.cc +++ b/paddle/fluid/framework/new_exec_test.cc @@ -56,7 +56,7 @@ int main() paddle::framework::build_op_func_list( main_prog, op_main_list, vec_main_func_list, global_scope); auto start = std::chrono::steady_clock::now(); - //ProfilerStart("new_executor.prof"); + ProfilerStart("new_executor.prof"); for ( size_t i = 0; i < 2320; ++i ) { if( i % 200 == 0) @@ -65,7 +65,7 @@ int main() } paddle::framework::exec_op_func_list( vec_main_func_list, op_main_list, global_scope ); } - //ProfilerStop(); + ProfilerStop(); auto end = std::chrono::steady_clock::now(); std::chrono::duration diff = end-start; -- GitLab