From 25d58db68cab98781e178e8e5fd7d77130c1d350 Mon Sep 17 00:00:00 2001 From: Yuanle Liu Date: Mon, 22 Aug 2022 14:24:32 +0800 Subject: [PATCH] remove trt_skip_layernorm_fuse_pass from gpu passes (#45293) --- paddle/fluid/framework/ir/CMakeLists.txt | 2 +- paddle/fluid/inference/api/paddle_pass_builder.cc | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/paddle/fluid/framework/ir/CMakeLists.txt b/paddle/fluid/framework/ir/CMakeLists.txt index cb80d8453d2..08820046188 100755 --- a/paddle/fluid/framework/ir/CMakeLists.txt +++ b/paddle/fluid/framework/ir/CMakeLists.txt @@ -167,6 +167,7 @@ if(WITH_TENSORRT) pass_library(trt_map_matmul_to_mul_pass inference) pass_library(trt_embedding_eltwise_layernorm_fuse_pass inference) pass_library(trt_multihead_matmul_fuse_pass inference) + pass_library(trt_skip_layernorm_fuse_pass inference) pass_library(preln_embedding_eltwise_layernorm_fuse_pass inference) pass_library(preln_skip_layernorm_fuse_pass inference) pass_library(set_transformer_input_convert_pass inference) @@ -177,7 +178,6 @@ endif() if(WITH_GPU OR WITH_ROCM) pass_library(cudnn_placement_pass base DEPS placement_pass_base) pass_library(embedding_eltwise_layernorm_fuse_pass inference) - pass_library(trt_skip_layernorm_fuse_pass inference) endif() if(WITH_MKLDNN) diff --git a/paddle/fluid/inference/api/paddle_pass_builder.cc b/paddle/fluid/inference/api/paddle_pass_builder.cc index 3bfccf11307..d7e08508577 100644 --- a/paddle/fluid/inference/api/paddle_pass_builder.cc +++ b/paddle/fluid/inference/api/paddle_pass_builder.cc @@ -167,7 +167,6 @@ const std::vector kGpuLowerPrecisionPasses{ "fc_fuse_pass", "fc_elementwise_layernorm_fuse_pass", "embedding_eltwise_layernorm_fuse_pass", - "trt_skip_layernorm_fuse_pass", "runtime_context_cache_pass", }; @@ -192,7 +191,6 @@ GpuPassStrategy::GpuPassStrategy() : PassStrategy({}) { "conv_bn_fuse_pass", // "conv_eltwiseadd_bn_fuse_pass", // "embedding_eltwise_layernorm_fuse_pass", // - "trt_skip_layernorm_fuse_pass", // "multihead_matmul_fuse_pass_v2", // "gpu_cpu_squeeze2_matmul_fuse_pass", // "gpu_cpu_reshape2_matmul_fuse_pass", // -- GitLab