diff --git a/inc/register/graph_optimizer/fusion_common/pattern_fusion_base_pass.h b/inc/register/graph_optimizer/fusion_common/pattern_fusion_base_pass.h index 0decb6f608be2010e07d27602e9aebfa72e4f87f..f6b98ef768cc3ffca7c54ed3657d507f1922e4e3 100644 --- a/inc/register/graph_optimizer/fusion_common/pattern_fusion_base_pass.h +++ b/inc/register/graph_optimizer/fusion_common/pattern_fusion_base_pass.h @@ -47,11 +47,7 @@ using PatternFusionBasePassImplPtr = std::shared_ptr; class PatternFusionBasePass : public GraphPass { public: using OpDesc = FusionPattern::OpDesc; -#ifdef ONLY_COMPILE_OPEN_SRC - using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, CmpKey>; -#endif using Mappings = std::vector; PatternFusionBasePass(); diff --git a/inc/register/graph_optimizer/graph_fusion/graph_fusion_pass_base.h b/inc/register/graph_optimizer/graph_fusion/graph_fusion_pass_base.h index a953c8374f1901affb9b11c18ed2d7936c42718a..06e79e8a17d7f01a12629d6fdf2ee111b10f776c 100644 --- a/inc/register/graph_optimizer/graph_fusion/graph_fusion_pass_base.h +++ b/inc/register/graph_optimizer/graph_fusion/graph_fusion_pass_base.h @@ -55,11 +55,7 @@ using PatternFusionBasePassImplPtr = std::shared_ptr; class GraphFusionPassBase : public GraphPass { public: using OpDesc = FusionPattern::OpDesc; -#ifdef ONLY_COMPILE_OPEN_SRC - using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, CmpKey>; -#endif using Mappings = std::vector; GraphFusionPassBase(); diff --git a/register/graph_optimizer/graph_fusion/pattern_fusion_base_pass_impl.h b/register/graph_optimizer/graph_fusion/pattern_fusion_base_pass_impl.h index ab52ee29015053b51a8024952ce8a3cae9e62def..cce844ad1c5fed74a32c93ad4c55b225ee7fd3ac 100644 --- a/register/graph_optimizer/graph_fusion/pattern_fusion_base_pass_impl.h +++ b/register/graph_optimizer/graph_fusion/pattern_fusion_base_pass_impl.h @@ -29,11 +29,7 @@ namespace fe { using OpDesc = FusionPattern::OpDesc; -#ifdef ONLY_COMPILE_OPEN_SRC -using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, CmpKey>; -#endif using Mappings = std::vector; using OpsKernelInfoStorePtr = std::shared_ptr; struct CandidateAndMapping { diff --git a/tests/ut/register/testcase/graph_fusion_clycle_detection_unittest.cc b/tests/ut/register/testcase/graph_fusion_clycle_detection_unittest.cc index 34f0d0a9fd97b4fba0d0ed482f76de32e3c13d98..c3b8080241957924bec50b576f2b660b9c16f8f5 100644 --- a/tests/ut/register/testcase/graph_fusion_clycle_detection_unittest.cc +++ b/tests/ut/register/testcase/graph_fusion_clycle_detection_unittest.cc @@ -95,11 +95,7 @@ static ComputeGraphPtr BuildFusionGraph01(std::vector &fusion_nodes fusion_nodes = {a, b, c}; return graph; } -#ifdef ONLY_COMPILE_OPEN_SRC -using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif TEST_F(UtestCycleDetection, cycle_detection_01) { std::vector fusion_nodes; auto graph = BuildFusionGraph01(fusion_nodes); diff --git a/tests/ut/register/testcase/register_graph_fusion.cc b/tests/ut/register/testcase/register_graph_fusion.cc index b55d15263553bc265c59aebbecefa6931ffce388..5bac3c950c48b99872dfd07461629cfcf4fdacaa 100644 --- a/tests/ut/register/testcase/register_graph_fusion.cc +++ b/tests/ut/register/testcase/register_graph_fusion.cc @@ -534,11 +534,7 @@ const char *kPatternRelu = "Relu"; string pass_name_test = "CastCastFusionPass"; class TestPass : public fe::PatternFusionBasePass { -#ifdef ONLY_COMPILE_OPEN_SRC - using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif protected: vector DefinePatterns() override { vector patterns; diff --git a/tests/ut/register/testcase/register_graph_fusion_2.cc b/tests/ut/register/testcase/register_graph_fusion_2.cc index 52cfc4111bfbdb29917a80ffbb21bb63a4e81b70..f5b739cbab098a9cc951bbc9ab9671631963fc1c 100644 --- a/tests/ut/register/testcase/register_graph_fusion_2.cc +++ b/tests/ut/register/testcase/register_graph_fusion_2.cc @@ -38,11 +38,7 @@ * NetOutput NetOutPut */ namespace fe { -#ifdef ONLY_COMPILE_OPEN_SRC -using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif class SwapMergeCastFusionTestPass : public PatternFusionBasePass { protected: vector DefinePatterns() override; diff --git a/tests/ut/register/testcase/register_graph_fusion_3.cc b/tests/ut/register/testcase/register_graph_fusion_3.cc index 7d2fa45e2eb02d2c9099c8dc6b69550caa652c38..ee184e54b74602c2c411def944f9cadc7200bb82 100644 --- a/tests/ut/register/testcase/register_graph_fusion_3.cc +++ b/tests/ut/register/testcase/register_graph_fusion_3.cc @@ -39,11 +39,7 @@ * NetOutput NetOutPut */ namespace fe { -#ifdef ONLY_COMPILE_OPEN_SRC -using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif class SwapMergeCastFusionTestPass3 : public GraphFusionPassBase { protected: vector DefinePatterns() override; diff --git a/tests/ut/register/testcase/register_graph_fusion_4.cc b/tests/ut/register/testcase/register_graph_fusion_4.cc index 3d4b551e97493e6e6709d6c3c3e06e0acedebe90..aa59bae44e4e9004cde9b3eda212a06952cf87b7 100644 --- a/tests/ut/register/testcase/register_graph_fusion_4.cc +++ b/tests/ut/register/testcase/register_graph_fusion_4.cc @@ -37,11 +37,7 @@ * NetOutput */ namespace fe { -#ifdef ONLY_COMPILE_OPEN_SRC -using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif using namespace ge; class TestSetOutputsPass1 : public GraphFusionPassBase { protected: diff --git a/tests/ut/register/testcase/register_graph_fusion_v2_utest.cc b/tests/ut/register/testcase/register_graph_fusion_v2_utest.cc index 5809e4c1230f1fec5ca293eb7b91a0a673969257..32c3a3567bc16bc1ce72444dc674499e68f5b69e 100644 --- a/tests/ut/register/testcase/register_graph_fusion_v2_utest.cc +++ b/tests/ut/register/testcase/register_graph_fusion_v2_utest.cc @@ -77,11 +77,7 @@ const char *kPatternRelu = "Relu"; string pass_name_test = "CastCastFusionPass"; class TestPass : public fe::PatternFusionBasePass { -#ifdef ONLY_COMPILE_OPEN_SRC - using Mapping = std::map, std::vector>; -#else using Mapping = std::map, std::vector, fe::CmpKey>; -#endif protected: vector DefinePatterns() override {