未验证 提交 96f36962 编写于 作者: W Wang Xin 提交者: GitHub

remove unused-local-typedefs warning on linux (#47513)

上级 c5d99138
...@@ -149,7 +149,6 @@ if(NOT WIN32) ...@@ -149,7 +149,6 @@ if(NOT WIN32)
-Wno-unused-parameter -Wno-unused-parameter
-Wno-unused-function -Wno-unused-function
-Wno-error=literal-suffix -Wno-error=literal-suffix
-Wno-error=unused-local-typedefs
-Wno-error=ignored-attributes # Warnings in Eigen, gcc 6.3 -Wno-error=ignored-attributes # Warnings in Eigen, gcc 6.3
-Wno-error=terminate # Warning in PADDLE_ENFORCE -Wno-error=terminate # Warning in PADDLE_ENFORCE
-Wno-error=int-in-bool-context # Warning in Eigen gcc 7.2 -Wno-error=int-in-bool-context # Warning in Eigen gcc 7.2
......
...@@ -54,7 +54,6 @@ class CCommInitOp : public framework::OperatorBase { ...@@ -54,7 +54,6 @@ class CCommInitOp : public framework::OperatorBase {
// TODO(wangxi): Put this in the unified header file // TODO(wangxi): Put this in the unified header file
#if defined(PADDLE_WITH_NCCL) || defined(PADDLE_WITH_RCCL) #if defined(PADDLE_WITH_NCCL) || defined(PADDLE_WITH_RCCL)
using UniqueId = ncclUniqueId; using UniqueId = ncclUniqueId;
using Place = platform::CUDAPlace;
using CommContext = platform::NCCLCommContext; using CommContext = platform::NCCLCommContext;
#elif defined(PADDLE_WITH_XPU_BKCL) #elif defined(PADDLE_WITH_XPU_BKCL)
using UniqueId = BKCLUniqueId; using UniqueId = BKCLUniqueId;
......
...@@ -143,7 +143,6 @@ class EltwiseMKLDNNGradKernel : public ElemwiseGradKernel<T> { ...@@ -143,7 +143,6 @@ class EltwiseMKLDNNGradKernel : public ElemwiseGradKernel<T> {
public: public:
void Compute(const framework::ExecutionContext& ctx) const override { void Compute(const framework::ExecutionContext& ctx) const override {
ElemwiseGradKernel<T>::Compute(ctx); ElemwiseGradKernel<T>::Compute(ctx);
using Tensor = phi::DenseTensor;
auto& dev_ctx = auto& dev_ctx =
ctx.template device_context<platform::MKLDNNDeviceContext>(); ctx.template device_context<platform::MKLDNNDeviceContext>();
......
...@@ -39,7 +39,6 @@ void RnnKernel(const Context& dev_ctx, ...@@ -39,7 +39,6 @@ void RnnKernel(const Context& dev_ctx,
DenseTensor* dropout_state, DenseTensor* dropout_state,
std::vector<DenseTensor*> state, std::vector<DenseTensor*> state,
DenseTensor* reserve) { DenseTensor* reserve) {
using XPUTyp = typename XPUTypeTrait<T>::Type;
if (dropout_state->IsInitialized()) { if (dropout_state->IsInitialized()) {
if (dropout_state->numel() != out->numel()) dropout_state->clear(); if (dropout_state->numel() != out->numel()) dropout_state->clear();
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册