Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
BaiXuePrincess
Paddle
提交
df23c7c3
P
Paddle
项目概览
BaiXuePrincess
/
Paddle
与 Fork 源项目一致
Fork自
PaddlePaddle / Paddle
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
df23c7c3
编写于
11月 24, 2022
作者:
P
PuQing
提交者:
GitHub
11月 24, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[PHI decoupling] remove "paddle/fluid/platform/enforce.h" in phi (#48049)
上级
e29c50c2
变更
32
展开全部
隐藏空白更改
内联
并排
Showing
32 changed file
with
633 addition
and
574 deletion
+633
-574
paddle/fluid/inference/check_symbol.sh
paddle/fluid/inference/check_symbol.sh
+1
-1
paddle/fluid/platform/CMakeLists.txt
paddle/fluid/platform/CMakeLists.txt
+0
-3
paddle/fluid/platform/enforce.h
paddle/fluid/platform/enforce.h
+0
-530
paddle/phi/backends/callback_manager.cc
paddle/phi/backends/callback_manager.cc
+1
-1
paddle/phi/backends/dynload/cudnn.cc
paddle/phi/backends/dynload/cudnn.cc
+1
-1
paddle/phi/backends/dynload/cufft.cc
paddle/phi/backends/dynload/cufft.cc
+1
-1
paddle/phi/backends/dynload/dynamic_loader.cc
paddle/phi/backends/dynload/dynamic_loader.cc
+1
-1
paddle/phi/backends/dynload/miopen.cc
paddle/phi/backends/dynload/miopen.cc
+1
-1
paddle/phi/backends/dynload/tensorrt.h
paddle/phi/backends/dynload/tensorrt.h
+1
-1
paddle/phi/backends/gpu/cuda/cuda_info.cc
paddle/phi/backends/gpu/cuda/cuda_info.cc
+1
-2
paddle/phi/backends/gpu/gpu_context.cc
paddle/phi/backends/gpu/gpu_context.cc
+2
-2
paddle/phi/backends/gpu/gpu_resources.cc
paddle/phi/backends/gpu/gpu_resources.cc
+1
-2
paddle/phi/backends/gpu/rocm/rocm_info.cc
paddle/phi/backends/gpu/rocm/rocm_info.cc
+2
-3
paddle/phi/backends/xpu/enforce_xpu.h
paddle/phi/backends/xpu/enforce_xpu.h
+1
-1
paddle/phi/backends/xpu/xpu_header.h
paddle/phi/backends/xpu/xpu_header.h
+1
-1
paddle/phi/core/CMakeLists.txt
paddle/phi/core/CMakeLists.txt
+4
-0
paddle/phi/core/cuda_stream.h
paddle/phi/core/cuda_stream.h
+1
-2
paddle/phi/core/enforce.h
paddle/phi/core/enforce.h
+595
-6
paddle/phi/core/external_error.proto
paddle/phi/core/external_error.proto
+1
-1
paddle/phi/kernels/autotune/CMakeLists.txt
paddle/phi/kernels/autotune/CMakeLists.txt
+5
-2
paddle/phi/kernels/funcs/concat_funcs.h
paddle/phi/kernels/funcs/concat_funcs.h
+1
-1
paddle/phi/kernels/funcs/cpu_vec.h
paddle/phi/kernels/funcs/cpu_vec.h
+1
-1
paddle/phi/kernels/funcs/cufft_util.h
paddle/phi/kernels/funcs/cufft_util.h
+1
-1
paddle/phi/kernels/funcs/gru_compute.h
paddle/phi/kernels/funcs/gru_compute.h
+1
-1
paddle/phi/kernels/funcs/hipfft_util.h
paddle/phi/kernels/funcs/hipfft_util.h
+1
-1
paddle/phi/kernels/funcs/lstm_compute.h
paddle/phi/kernels/funcs/lstm_compute.h
+1
-1
paddle/phi/kernels/funcs/math_function.h
paddle/phi/kernels/funcs/math_function.h
+1
-1
paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu
paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu
+1
-1
paddle/phi/kernels/gpu/batch_norm_kernel.cu
paddle/phi/kernels/gpu/batch_norm_kernel.cu
+1
-1
paddle/phi/kernels/gpu/cholesky_solve_kernel.cu
paddle/phi/kernels/gpu/cholesky_solve_kernel.cu
+1
-1
paddle/phi/kernels/gpu/class_center_sample_kernel.cu
paddle/phi/kernels/gpu/class_center_sample_kernel.cu
+1
-1
tools/externalError/start.sh
tools/externalError/start.sh
+1
-1
未找到文件。
paddle/fluid/inference/check_symbol.sh
浏览文件 @
df23c7c3
...
...
@@ -18,7 +18,7 @@ lib=$1
if
[
$#
-ne
1
]
;
then
echo
"No input library"
;
exit
-1
;
fi
num_paddle_syms
=
$(
nm
-D
"
${
lib
}
"
|
grep
-c
paddle
)
num_google_syms
=
$(
nm
-D
"
${
lib
}
"
|
grep
google |
grep
-v
paddle |
grep
-v
brpc |
grep
-c
"T "
)
num_google_syms
=
$(
nm
-D
"
${
lib
}
"
|
grep
google |
grep
-v
paddle |
grep
-v
phi |
grep
-v
brpc |
grep
-c
"T "
)
if
[
$num_paddle_syms
-le
0
]
;
then
echo
"Have no paddle symbols"
;
exit
-1
;
fi
if
[
$num_google_syms
-ge
1
]
;
then
echo
"Have some google symbols"
;
exit
-1
;
fi
...
...
paddle/fluid/platform/CMakeLists.txt
浏览文件 @
df23c7c3
proto_library
(
profiler_proto SRCS profiler.proto DEPS framework_proto
simple_threadpool
)
if
(
WITH_GPU
)
proto_library
(
external_error_proto SRCS external_error.proto
)
endif
()
if
(
WITH_PYTHON
)
py_proto_compile
(
profiler_py_proto SRCS profiler.proto
)
add_custom_target
(
profiler_py_proto_init ALL COMMAND
${
CMAKE_COMMAND
}
-E
...
...
paddle/fluid/platform/enforce.h
浏览文件 @
df23c7c3
此差异已折叠。
点击以展开。
paddle/phi/backends/callback_manager.cc
浏览文件 @
df23c7c3
...
...
@@ -17,8 +17,8 @@
#include <ThreadPool.h>
#include "paddle/fluid/platform/device/device_wrapper.h"
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/device_guard.h"
#include "paddle/phi/core/enforce.h"
namespace
phi
{
...
...
paddle/phi/backends/dynload/cudnn.cc
浏览文件 @
df23c7c3
...
...
@@ -14,7 +14,7 @@ limitations under the License. */
#include "paddle/phi/backends/dynload/cudnn.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
namespace
phi
{
namespace
dynload
{
...
...
paddle/phi/backends/dynload/cufft.cc
浏览文件 @
df23c7c3
...
...
@@ -14,7 +14,7 @@ limitations under the License. */
#include "paddle/phi/backends/dynload/cufft.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
namespace
phi
{
namespace
dynload
{
...
...
paddle/phi/backends/dynload/dynamic_loader.cc
浏览文件 @
df23c7c3
...
...
@@ -17,8 +17,8 @@ limitations under the License. */
#include <string>
#include <vector>
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/dynload/cupti_lib_path.h"
#include "paddle/phi/core/enforce.h"
#if defined(_WIN32)
#include <windows.h>
...
...
paddle/phi/backends/dynload/miopen.cc
浏览文件 @
df23c7c3
...
...
@@ -14,7 +14,7 @@ limitations under the License. */
#include "paddle/phi/backends/dynload/miopen.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
namespace
phi
{
namespace
dynload
{
...
...
paddle/phi/backends/dynload/tensorrt.h
浏览文件 @
df23c7c3
...
...
@@ -21,8 +21,8 @@ limitations under the License. */
#include <mutex> // NOLINT
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/dynload/dynamic_loader.h"
#include "paddle/phi/core/enforce.h"
namespace
phi
{
namespace
dynload
{
...
...
paddle/phi/backends/gpu/cuda/cuda_info.cc
浏览文件 @
df23c7c3
...
...
@@ -14,8 +14,7 @@
#include "paddle/phi/backends/gpu/gpu_info.h"
// TODO(phi): remove fluid headers.
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/enforce.h"
static
std
::
once_flag
g_device_props_size_init_flag
;
static
std
::
vector
<
std
::
unique_ptr
<
std
::
once_flag
>>
g_device_props_init_flags
;
...
...
paddle/phi/backends/gpu/gpu_context.cc
浏览文件 @
df23c7c3
...
...
@@ -21,6 +21,7 @@ limitations under the License. */
#include <future>
#include <memory>
#include <mutex>
#include <unordered_map>
#include "glog/logging.h"
#include "paddle/phi/api/ext/exception.h"
...
...
@@ -54,8 +55,7 @@ limitations under the License. */
// without eigen.
#include "unsupported/Eigen/CXX11/Tensor"
// TODO(phi): remove fluid header.
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/enforce.h"
namespace
phi
{
...
...
paddle/phi/backends/gpu/gpu_resources.cc
浏览文件 @
df23c7c3
...
...
@@ -32,8 +32,7 @@
#include "unsupported/Eigen/CXX11/Tensor"
// TODO(phi): remove fluid header.
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/enforce.h"
namespace
phi
{
...
...
paddle/phi/backends/gpu/rocm/rocm_info.cc
浏览文件 @
df23c7c3
...
...
@@ -16,12 +16,11 @@
#include "paddle/phi/backends/gpu/gpu_info.h"
// TODO(phi): remove fluid headers.
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/enforce.h"
static
std
::
once_flag
g_device_props_size_init_flag
;
static
std
::
vector
<
std
::
unique_ptr
<
std
::
once_flag
>>
g_device_props_init_flags
;
static
std
::
vector
<
p
addle
::
gpuDeviceProp
>
g_device_props
;
static
std
::
vector
<
p
hi
::
gpuDeviceProp
>
g_device_props
;
namespace
phi
{
namespace
backends
{
...
...
paddle/phi/backends/xpu/enforce_xpu.h
浏览文件 @
df23c7c3
...
...
@@ -14,8 +14,8 @@ limitations under the License. */
#pragma once
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/xpu/xpu_header.h"
#include "paddle/phi/core/enforce.h"
#ifdef PADDLE_WITH_XPU_BKCL
#include "xpu/bkcl.h"
#endif
...
...
paddle/phi/backends/xpu/xpu_header.h
浏览文件 @
df23c7c3
...
...
@@ -19,9 +19,9 @@ limitations under the License. */
#include <string>
#include <unordered_map>
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/common/bfloat16.h"
#include "paddle/phi/common/float16.h"
#include "paddle/phi/core/enforce.h"
#include "xpu/runtime.h"
#include "xpu/runtime_ex.h"
#include "xpu/xdnn.h"
...
...
paddle/phi/core/CMakeLists.txt
浏览文件 @
df23c7c3
# compatible utils used for fluid op system
add_subdirectory
(
compat
)
if
(
WITH_GPU
)
proto_library
(
external_error_proto SRCS external_error.proto
)
endif
()
cc_library
(
errors SRCS errors.cc
)
set
(
phi_enforce_deps errors flags
)
if
(
WITH_GPU
)
...
...
paddle/phi/core/cuda_stream.h
浏览文件 @
df23c7c3
...
...
@@ -28,8 +28,7 @@ using gpuStream_t = cudaStream_t;
using
gpuStream_t
=
hipStream_t
;
#endif
// TODO(phi): remove fluid headers.
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/enforce.h"
namespace
phi
{
...
...
paddle/phi/core/enforce.h
浏览文件 @
df23c7c3
此差异已折叠。
点击以展开。
paddle/
fluid/platform
/external_error.proto
→
paddle/
phi/core
/external_error.proto
浏览文件 @
df23c7c3
...
...
@@ -13,7 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
syntax
=
"proto2"
;
package
p
addle
.
platform
.proto
;
package
p
hi
.
proto
;
// (NOTE:zhouwei): ApiType describes which kind of external third party API
// More external third party API can be added.
...
...
paddle/phi/kernels/autotune/CMakeLists.txt
浏览文件 @
df23c7c3
...
...
@@ -2,9 +2,12 @@ if(WITH_CUDNN_FRONTEND)
cc_library
(
cache
SRCS cache.cc
DEPS cudnn-frontend
)
DEPS cudnn-frontend
phi_enforce
)
else
()
cc_library
(
cache SRCS cache.cc
)
cc_library
(
cache
SRCS cache.cc
DEPS phi_enforce
)
endif
()
cc_library
(
switch_autotune
...
...
paddle/phi/kernels/funcs/concat_funcs.h
浏览文件 @
df23c7c3
...
...
@@ -14,7 +14,7 @@
#pragma once
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
#include "paddle/phi/core/errors.h"
namespace
phi
{
namespace
funcs
{
...
...
paddle/phi/kernels/funcs/cpu_vec.h
浏览文件 @
df23c7c3
...
...
@@ -18,7 +18,7 @@ limitations under the License. */
#include <string>
#include "paddle/fluid/platform/cpu_info.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
#ifdef PADDLE_WITH_MKLML
#include "paddle/phi/backends/dynload/mklml.h"
...
...
paddle/phi/kernels/funcs/cufft_util.h
浏览文件 @
df23c7c3
...
...
@@ -15,9 +15,9 @@
#pragma once
#include <vector>
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/dynload/cufft.h"
#include "paddle/phi/core/ddim.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/kernels/funcs/fft.h"
#include "paddle/phi/kernels/funcs/fft_key.h"
...
...
paddle/phi/kernels/funcs/gru_compute.h
浏览文件 @
df23c7c3
...
...
@@ -12,7 +12,7 @@ limitations under the License. */
#pragma once
#include "paddle/fluid/platform/device_context.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
#include "paddle/phi/kernels/funcs/detail/activation_functions.h"
namespace
phi
{
...
...
paddle/phi/kernels/funcs/hipfft_util.h
浏览文件 @
df23c7c3
...
...
@@ -15,8 +15,8 @@
#pragma once
#include <vector>
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/dynload/hipfft.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/kernels/funcs/fft.h"
#include "paddle/phi/kernels/funcs/fft_key.h"
...
...
paddle/phi/kernels/funcs/lstm_compute.h
浏览文件 @
df23c7c3
...
...
@@ -15,7 +15,7 @@ limitations under the License. */
#pragma once
#include "paddle/fluid/platform/device_context.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
#include "paddle/phi/kernels/funcs/detail/activation_functions.h"
namespace
phi
{
...
...
paddle/phi/kernels/funcs/math_function.h
浏览文件 @
df23c7c3
...
...
@@ -21,8 +21,8 @@ limitations under the License. */
#include "paddle/fluid/framework/tensor.h"
#include "paddle/fluid/framework/tensor_util.h"
#include "paddle/fluid/platform/device_context.h"
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/core/dense_tensor.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/core/utils/data_type.h"
#include "paddle/phi/kernels/funcs/eigen/common.h"
...
...
paddle/phi/kernels/gpu/batch_norm_grad_kernel.cu
浏览文件 @
df23c7c3
...
...
@@ -15,10 +15,10 @@
#include "paddle/fluid/operators/layout_utils.h"
#include "paddle/fluid/operators/norm_utils.cu.h"
#include "paddle/fluid/platform/device/gpu/gpu_dnn.h"
#include "paddle/fluid/platform/enforce.h"
#include "paddle/fluid/platform/flags.h"
#include "paddle/phi/backends/gpu/gpu_context.h"
#include "paddle/phi/common/layout.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/core/kernel_registry.h"
#include "paddle/phi/kernels/batch_norm_kernel.h"
#include "paddle/phi/kernels/empty_kernel.h"
...
...
paddle/phi/kernels/gpu/batch_norm_kernel.cu
浏览文件 @
df23c7c3
...
...
@@ -23,10 +23,10 @@ namespace cub = hipcub;
#include "paddle/fluid/operators/layout_utils.h"
#include "paddle/fluid/operators/norm_utils.cu.h"
#include "paddle/fluid/platform/device/gpu/gpu_dnn.h"
#include "paddle/fluid/platform/enforce.h"
#include "paddle/fluid/platform/flags.h"
#include "paddle/phi/backends/gpu/gpu_context.h"
#include "paddle/phi/common/layout.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/core/kernel_registry.h"
#include "paddle/phi/kernels/batch_norm_kernel.h"
#include "paddle/phi/kernels/funcs/batch_norm_utils.h"
...
...
paddle/phi/kernels/gpu/cholesky_solve_kernel.cu
浏览文件 @
df23c7c3
...
...
@@ -15,10 +15,10 @@
#ifndef PADDLE_WITH_HIP
// HIP not support cusolver
#include "paddle/fluid/platform/enforce.h"
#include "paddle/phi/backends/dynload/cusolver.h"
#include "paddle/phi/backends/gpu/gpu_context.h"
#include "paddle/phi/common/complex.h"
#include "paddle/phi/core/enforce.h"
#include "paddle/phi/core/kernel_registry.h"
#include "paddle/phi/kernels/funcs/lapack/lapack_function.h"
#include "paddle/phi/kernels/impl/cholesky_solve_kernel_impl.h"
...
...
paddle/phi/kernels/gpu/class_center_sample_kernel.cu
浏览文件 @
df23c7c3
...
...
@@ -30,7 +30,7 @@ namespace cub = hipcub;
#include <random>
#include "paddle/fluid/framework/tensor_util.h"
#include "paddle/
fluid/platform
/enforce.h"
#include "paddle/
phi/core
/enforce.h"
#if defined(PADDLE_WITH_NCCL) || defined(PADDLE_WITH_RCCL)
#include "paddle/fluid/distributed/collective/ProcessGroup.h"
...
...
tools/externalError/start.sh
浏览文件 @
df23c7c3
...
...
@@ -29,7 +29,7 @@ else
echo
"please run on Mac/Linux"
exit
1
fi
protobuf/bin/protoc
-I
../../paddle/
fluid/platform/
--python_out
.
../../paddle/fluid/platform
/external_error.proto
protobuf/bin/protoc
-I
../../paddle/
phi/core/
--python_out
.
../../paddle/phi/core
/external_error.proto
python3.7 spider.py
tar
czvf externalErrorMsg_
$(
date
+
'%Y%m%d'
)
.tar.gz externalErrorMsg.pb
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录