From 5048640b9b0f96570d777c54c62246e26ac998fa Mon Sep 17 00:00:00 2001 From: cyber-pioneer Date: Mon, 25 Sep 2023 10:29:08 +0000 Subject: [PATCH] fix compile --- .../codegen/templates/rule/vjp/generated/generated_vjp.cc.j2 | 1 + paddle/fluid/primitive/utils/CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/paddle/fluid/primitive/codegen/templates/rule/vjp/generated/generated_vjp.cc.j2 b/paddle/fluid/primitive/codegen/templates/rule/vjp/generated/generated_vjp.cc.j2 index 18da2b7f05dc18..59a6f7305411f5 100644 --- a/paddle/fluid/primitive/codegen/templates/rule/vjp/generated/generated_vjp.cc.j2 +++ b/paddle/fluid/primitive/codegen/templates/rule/vjp/generated/generated_vjp.cc.j2 @@ -102,6 +102,7 @@ vjp_res = ConstructVjpResultByStopGradients(vjp_res, stop_gradients); {% macro body_prim(api) %} FLAGS_tensor_operants_mode = "static"; +VLOG(4) << "PIR Static Prim API {{api.name}} call"; {% for i in range(api.outputs|length) %} {% if api.outputs[i].typename=='Tensor' %} paddle::Tensor* {{api.outputs[i].name}} = !stop_gradients[{{i}}][0] ? &vjp_res[{{i}}][0] : nullptr; diff --git a/paddle/fluid/primitive/utils/CMakeLists.txt b/paddle/fluid/primitive/utils/CMakeLists.txt index 044198c827fb2d..d33bb8fe15d5dd 100644 --- a/paddle/fluid/primitive/utils/CMakeLists.txt +++ b/paddle/fluid/primitive/utils/CMakeLists.txt @@ -7,4 +7,4 @@ endif() cc_library( primitive_static_utils_experimental SRCS static_utils.cc - DEPS phi common_infer_shape_functions) + DEPS phi common_infer_shape_functions pd_op_dialect_api)