已合并
适配PG short_soc_version #862
xufeng12121创建于 5月19日
适配PG short_soc_version #862
已合并
共 10 个文件变更+11-11
| @@ -58,7 +58,7 @@ set(BISHENG_FLAGS "" CACHE STRING "bisheng compiler flags") | |||
| 58 | set(KERNEL_TEMPLATE_INPUT "" CACHE STRING " kernel template input") | 58 | set(KERNEL_TEMPLATE_INPUT "" CACHE STRING " kernel template input") |
| 59 | set(BUILD_MODE "" CACHE STRING "build mode -O0/O1/O2/O3") | 59 | set(BUILD_MODE "" CACHE STRING "build mode -O0/O1/O2/O3") |
| 60 | set(ASCEND_COMPUTE_UNIT "ascend910b" CACHE STRING "soc that need to be compiled") | 60 | set(ASCEND_COMPUTE_UNIT "ascend910b" CACHE STRING "soc that need to be compiled") |
| 61 | -set(ASCEND_ALL_COMPUTE_UNIT "ascend031;ascend035;ascend310b;ascend310p;ascend610lite;ascend630;ascend910;ascend910b;ascend910_93;ascend950;mc62cm12a;kirinx90;kirin9030" CACHE STRING "all soc list") | 61 | +set(ASCEND_ALL_COMPUTE_UNIT "ascend031;ascend035;ascend310b;ascend310p;ascend610lite;ascend630;ascend910;ascend910b;ascend910_93;ascend950;mc62;kirinx90;kirin9030" CACHE STRING "all soc list") |
| 62 | if(NOT CANN_3RD_LIB_PATH) | 62 | if(NOT CANN_3RD_LIB_PATH) |
| 63 | set(CANN_3RD_LIB_PATH ${PROJECT_SOURCE_DIR}/third_party CACHE STRING "cann third party lib path") | 63 | set(CANN_3RD_LIB_PATH ${PROJECT_SOURCE_DIR}/third_party CACHE STRING "cann third party lib path") |
| 64 | endif() | 64 | endif() |
| @@ -13,7 +13,7 @@ set -e | |||
| 13 | RELEASE_TARGETS=("ophost" "opapi" "opgraph" "opkernel" "opkernel_aicpu" "onnxplugin") | 13 | RELEASE_TARGETS=("ophost" "opapi" "opgraph" "opkernel" "opkernel_aicpu" "onnxplugin") |
| 14 | UT_TARGETS=("ophost_test" "opapi_test" "opgraph_test" "opkernel_test" "opkernel_aicpu_test") | 14 | UT_TARGETS=("ophost_test" "opapi_test" "opgraph_test" "opkernel_test" "opkernel_aicpu_test") |
| 15 | SUPPORT_COMPUTE_UNIT_SHORT=("ascend031" "ascend035" "ascend310b" "ascend310p" "ascend610lite" "ascend630" | 15 | SUPPORT_COMPUTE_UNIT_SHORT=("ascend031" "ascend035" "ascend310b" "ascend310p" "ascend610lite" "ascend630" |
| 16 | - "ascend910_93" "ascend950" "ascend910b" "ascend910" "mc62cm12a" "kirinx90" "kirin9030") | 16 | + "ascend910_93" "ascend950" "ascend910b" "ascend910" "mc62" "kirinx90" "kirin9030") |
| 17 | 17 | ||
| 18 | # 所有支持的短选项 | 18 | # 所有支持的短选项 |
| 19 | SUPPORTED_SHORT_OPTS="hj:vO:uf:-:" | 19 | SUPPORTED_SHORT_OPTS="hj:vO:uf:-:" |
| @@ -417,7 +417,7 @@ usage() { | |||
| 417 | echo "" | 417 | echo "" |
| 418 | echo " --ops Compile specified operator, use snake name, like: --ops=grid_sample,iou_v2, use ',' to separate different operator" | 418 | echo " --ops Compile specified operator, use snake name, like: --ops=grid_sample,iou_v2, use ',' to separate different operator" |
| 419 | echo " --soc Compile binary with specified Ascend SoC, like: --soc=ascend910b,ascend910_93,ascend950 use ',' to separate different SoC" | 419 | echo " --soc Compile binary with specified Ascend SoC, like: --soc=ascend910b,ascend910_93,ascend950 use ',' to separate different SoC" |
| 420 | - echo " --soc supported parameters must only in [ascend031 ascend035 ascend310b ascend310p ascend610lite ascend630 ascend910_93 ascend950 ascend910b ascend910 mc62cm12a kirinx90 kirin9030], A3(--soc=ascend910_93)" | 420 | + echo " --soc supported parameters must only in [ascend031 ascend035 ascend310b ascend310p ascend610lite ascend630 ascend910_93 ascend950 ascend910b ascend910 mc62 kirinx90 kirin9030], A3(--soc=ascend910_93)" |
| 421 | echo " --vendor_name Specify the custom operator package vendor name, like: --vendor_name=customize, default to customize-cv" | 421 | echo " --vendor_name Specify the custom operator package vendor name, like: --vendor_name=customize, default to customize-cv" |
| 422 | echo " --aicpu build aicpu task" | 422 | echo " --aicpu build aicpu task" |
| 423 | echo " --opgraph build op_graph_cv.so" | 423 | echo " --opgraph build op_graph_cv.so" |
| @@ -18,6 +18,6 @@ foreach(SUB_DIR ${CURRENT_DIRS}) | |||
| 18 | endif() | 18 | endif() |
| 19 | endforeach() | 19 | endforeach() |
| 20 | 20 | ||
| 21 | -set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62cm12a") | 21 | +set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62") |
| 22 | set(SUPPORT_TILING_DIR "arch35" "arch35") | 22 | set(SUPPORT_TILING_DIR "arch35" "arch35") |
| 23 | add_all_modules_sources(OPTYPE aipp ACLNNTYPE aclnn_exclude COMPUTE_UNIT ${SUPPORT_COMPUTE_UNIT} TILING_DIR ${SUPPORT_TILING_DIR} DISABLE_IN_OPP TRUE) | 23 | add_all_modules_sources(OPTYPE aipp ACLNNTYPE aclnn_exclude COMPUTE_UNIT ${SUPPORT_COMPUTE_UNIT} TILING_DIR ${SUPPORT_TILING_DIR} DISABLE_IN_OPP TRUE) |
| @@ -141,7 +141,7 @@ public: | |||
| 141 | .DynamicShapeSupportFlag(true) | 141 | .DynamicShapeSupportFlag(true) |
| 142 | .NeedCheckSupportFlag(false) | 142 | .NeedCheckSupportFlag(false) |
| 143 | .ExtendCfgInfo("opFile.value", "grid_sample_apt");; | 143 | .ExtendCfgInfo("opFile.value", "grid_sample_apt");; |
| 144 | - this->AICore().AddConfig("mc62cm12a", aicore95_config); | 144 | + this->AICore().AddConfig("mc62", aicore95_config); |
| 145 | this->AICore().AddConfig("ascend950", aicore95_config); | 145 | this->AICore().AddConfig("ascend950", aicore95_config); |
| 146 | 146 | ||
| 147 | OpAICoreConfig config_310p = Get310PCoreConfig(); | 147 | OpAICoreConfig config_310p = Get310PCoreConfig(); |
| @@ -20,7 +20,7 @@ foreach(SUB_DIR ${CURRENT_DIRS}) | |||
| 20 | endif() | 20 | endif() |
| 21 | endforeach() | 21 | endforeach() |
| 22 | 22 | ||
| 23 | -set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62cm12a") | 23 | +set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62") |
| 24 | 24 | ||
| 25 | set(SUPPORT_TILING_DIR "arch35" "arch35") | 25 | set(SUPPORT_TILING_DIR "arch35" "arch35") |
| 26 | 26 | ||
| @@ -66,7 +66,7 @@ public: | |||
| 66 | .DynamicShapeSupportFlag(true) | 66 | .DynamicShapeSupportFlag(true) |
| 67 | .ExtendCfgInfo("opFile.value", "resize_bilinear_v2_apt"); | 67 | .ExtendCfgInfo("opFile.value", "resize_bilinear_v2_apt"); |
| 68 | this->AICore().AddConfig("ascend950", aicoreConfig); | 68 | this->AICore().AddConfig("ascend950", aicoreConfig); |
| 69 | - this->AICore().AddConfig("mc62cm12a", aicoreConfig); | 69 | + this->AICore().AddConfig("mc62", aicoreConfig); |
| 70 | } | 70 | } |
| 71 | }; | 71 | }; |
| 72 | 72 | ||
| @@ -20,7 +20,7 @@ foreach(SUB_DIR ${CURRENT_DIRS}) | |||
| 20 | endif() | 20 | endif() |
| 21 | endforeach() | 21 | endforeach() |
| 22 | 22 | ||
| 23 | -set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62cm12a") | 23 | +set(SUPPORT_COMPUTE_UNIT "ascend950" "mc62") |
| 24 | 24 | ||
| 25 | set(SUPPORT_TILING_DIR "arch35" "arch35") | 25 | set(SUPPORT_TILING_DIR "arch35" "arch35") |
| 26 | 26 | ||
| @@ -65,7 +65,7 @@ class ResizeNearestNeighborV2 : public OpDef { | |||
| 65 | .DynamicShapeSupportFlag(true) | 65 | .DynamicShapeSupportFlag(true) |
| 66 | .ExtendCfgInfo("opFile.value", "resize_nearest_neighbor_v2_apt"); | 66 | .ExtendCfgInfo("opFile.value", "resize_nearest_neighbor_v2_apt"); |
| 67 | this->AICore().AddConfig("ascend950", aicoreConfig); | 67 | this->AICore().AddConfig("ascend950", aicoreConfig); |
| 68 | - this->AICore().AddConfig("mc62cm12a", aicoreConfig); | 68 | + this->AICore().AddConfig("mc62", aicoreConfig); |
| 69 | } | 69 | } |
| 70 | }; | 70 | }; |
| 71 | 71 | ||
| @@ -31,7 +31,7 @@ WMODES = stat.S_IWUSR | stat.S_IRUSR | |||
| 31 | SOC_MAP_EXT = {'ascend310p': 'Ascend310P3', 'ascend310b': 'Ascend310B1', | 31 | SOC_MAP_EXT = {'ascend310p': 'Ascend310P3', 'ascend310b': 'Ascend310B1', |
| 32 | 'ascend910': 'Ascend910A', 'ascend910b': 'Ascend910B1', | 32 | 'ascend910': 'Ascend910A', 'ascend910b': 'Ascend910B1', |
| 33 | 'ascend910_93': 'Ascend910_9391', 'kirinx90': 'KirinX90', | 33 | 'ascend910_93': 'Ascend910_9391', 'kirinx90': 'KirinX90', |
| 34 | - 'kirin9030': 'Kirin9030', 'mc62cm12a': 'MC62CM12AA'} | 34 | + 'kirin9030': 'Kirin9030', 'mc62': 'MC62CM12AA'} |
| 35 | BIN_CMD = 'asc_opc $1 --main_func={fun} --input_param={param} --soc_version={soc} \ | 35 | BIN_CMD = 'asc_opc $1 --main_func={fun} --input_param={param} --soc_version={soc} \ |
| 36 | --output=$2 --impl_mode={impl} --simplified_key_mode=0 --op_mode=dynamic\n' | 36 | --output=$2 --impl_mode={impl} --simplified_key_mode=0 --op_mode=dynamic\n' |
| 37 | SET_PLOG_LEVEL_ERROR = "export ASCEND_GLOBAL_LOG_LEVEL=3\n" | 37 | SET_PLOG_LEVEL_ERROR = "export ASCEND_GLOBAL_LOG_LEVEL=3\n" |
| @@ -42,7 +42,7 @@ SOC_TO_SHORT_SOC_MAP = { | |||
| 42 | "ascend310p3vir08": "ascend310p", | 42 | "ascend310p3vir08": "ascend310p", |
| 43 | "ascend310b1": "ascend310b", | 43 | "ascend310b1": "ascend310b", |
| 44 | "bs9sx1aa": "bs9sx1a", | 44 | "bs9sx1aa": "bs9sx1a", |
| 45 | - "mc62cm12a": "mc62cm12a" | 45 | + "mc62": "mc62" |
| 46 | } | 46 | } |
| 47 | CONFLICT_KEYWORDS = { | 47 | CONFLICT_KEYWORDS = { |
| 48 | "and", "as", "assert", "break", "class", "continue", "def", "del", "elif", "else", | 48 | "and", "as", "assert", "break", "class", "continue", "def", "del", "elif", "else", |