未验证 提交 8aa1772c 编写于 作者: H huangjiyi 提交者: GitHub

fix compile errors when using shared phi on windows (#56915)

* update

* fix bug

* fix bug

* fix bug

* fix bug

* rerun ci

* turn off shared_phi
上级 7d8402a8
...@@ -45,7 +45,7 @@ PD_DECLARE_bool(new_executor_use_local_scope); ...@@ -45,7 +45,7 @@ PD_DECLARE_bool(new_executor_use_local_scope);
PHI_DECLARE_bool(check_nan_inf); PHI_DECLARE_bool(check_nan_inf);
PD_DECLARE_bool(benchmark); PD_DECLARE_bool(benchmark);
PD_DECLARE_uint64(executor_log_deps_every_microseconds); PHI_DECLARE_uint64(executor_log_deps_every_microseconds);
PHI_DECLARE_bool(new_executor_use_cuda_graph); PHI_DECLARE_bool(new_executor_use_cuda_graph);
PHI_DECLARE_bool(enable_new_ir_in_executor); PHI_DECLARE_bool(enable_new_ir_in_executor);
#if defined(PADDLE_WITH_CUDA) || defined(PADDLE_WITH_HIP) #if defined(PADDLE_WITH_CUDA) || defined(PADDLE_WITH_HIP)
......
...@@ -26,7 +26,7 @@ limitations under the License. */ ...@@ -26,7 +26,7 @@ limitations under the License. */
#include "paddle/phi/core/kernel_factory.h" #include "paddle/phi/core/kernel_factory.h"
#include "paddle/utils/flags.h" #include "paddle/utils/flags.h"
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
namespace paddle { namespace paddle {
namespace framework { namespace framework {
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
PHI_DECLARE_bool(use_mkldnn); PHI_DECLARE_bool(use_mkldnn);
PHI_DECLARE_string(tracer_mkldnn_ops_on); PHI_DECLARE_string(tracer_mkldnn_ops_on);
PHI_DECLARE_string(tracer_mkldnn_ops_off); PHI_DECLARE_string(tracer_mkldnn_ops_off);
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
namespace paddle { namespace paddle {
namespace imperative { namespace imperative {
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
#include "paddle/fluid/platform/macros.h" #include "paddle/fluid/platform/macros.h"
#include "paddle/phi/core/compat/arg_map_context.h" #include "paddle/phi/core/compat/arg_map_context.h"
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
namespace paddle { namespace paddle {
namespace imperative { namespace imperative {
......
...@@ -69,7 +69,7 @@ typedef SSIZE_T ssize_t; ...@@ -69,7 +69,7 @@ typedef SSIZE_T ssize_t;
#include "paddle/utils/pybind.h" #include "paddle/utils/pybind.h"
PHI_DECLARE_bool(set_to_1d); PHI_DECLARE_bool(set_to_1d);
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
namespace paddle { namespace paddle {
namespace pybind { namespace pybind {
......
...@@ -13,11 +13,11 @@ See the License for the specific language governing permissions and ...@@ -13,11 +13,11 @@ See the License for the specific language governing permissions and
limitations under the License. */ limitations under the License. */
#include "paddle/phi/api/lib/api_gen_utils.h" #include "paddle/phi/api/lib/api_gen_utils.h"
#include "paddle/phi/core/flags.h"
#include "paddle/phi/core/visit_type.h" #include "paddle/phi/core/visit_type.h"
#include "paddle/phi/kernels/strided_copy_kernel.h" #include "paddle/phi/kernels/strided_copy_kernel.h"
#include "paddle/utils/flags.h"
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
#include "glog/logging.h" #include "glog/logging.h"
......
...@@ -21,15 +21,15 @@ limitations under the License. */ ...@@ -21,15 +21,15 @@ limitations under the License. */
#include "paddle/phi/api/lib/utils/allocator.h" #include "paddle/phi/api/lib/utils/allocator.h"
#include "paddle/phi/backends/context_pool.h" #include "paddle/phi/backends/context_pool.h"
#include "paddle/phi/core/distributed/auto_parallel/dist_tensor.h" #include "paddle/phi/core/distributed/auto_parallel/dist_tensor.h"
#include "paddle/phi/core/flags.h"
#include "paddle/phi/core/kernel_registry.h" #include "paddle/phi/core/kernel_registry.h"
#include "paddle/phi/core/tensor_utils.h" #include "paddle/phi/core/tensor_utils.h"
#include "paddle/phi/core/visit_type.h" #include "paddle/phi/core/visit_type.h"
#include "paddle/phi/kernels/cast_kernel.h" #include "paddle/phi/kernels/cast_kernel.h"
#include "paddle/phi/kernels/contiguous_kernel.h" #include "paddle/phi/kernels/contiguous_kernel.h"
#include "paddle/phi/kernels/transfer_layout_kernel.h" #include "paddle/phi/kernels/transfer_layout_kernel.h"
#include "paddle/utils/flags.h"
PD_DECLARE_bool(use_stride_kernel); PHI_DECLARE_bool(use_stride_kernel);
namespace paddle { namespace paddle {
namespace experimental { namespace experimental {
......
...@@ -25,12 +25,11 @@ ...@@ -25,12 +25,11 @@
#if defined(PADDLE_WITH_CUSTOM_DEVICE) #if defined(PADDLE_WITH_CUSTOM_DEVICE)
#include "paddle/phi/backends/custom/custom_device_op_list.h" #include "paddle/phi/backends/custom/custom_device_op_list.h"
#endif #endif
#include "paddle/fluid/platform/flags.h"
#include "paddle/phi/core/compat/op_utils.h" #include "paddle/phi/core/compat/op_utils.h"
#include "paddle/phi/core/flags.h"
#include "paddle/utils/string/string_helper.h" #include "paddle/utils/string/string_helper.h"
PADDLE_DEFINE_EXPORTED_bool( PHI_DEFINE_EXPORTED_bool(use_stride_kernel,
use_stride_kernel,
true, true,
"Whether to use strdie kernel if op support stride."); "Whether to use strdie kernel if op support stride.");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册