已合并
编译优化:减小mm算子的头文件包含,提高编译速度 #848
chen-shuai创建于 1月21日
编译优化:减小mm算子的头文件包含,提高编译速度 #848
已合并
共 93 个文件变更+183-169
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | namespace BatchMatMulV3Advanced { | 23 | namespace BatchMatMulV3Advanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | namespace BatchMatMulV3Advanced { | 23 | namespace BatchMatMulV3Advanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | namespace BatchMatMulV3Advanced { | 22 | namespace BatchMatMulV3Advanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | namespace BatchMatMulV3Advanced { | 21 | namespace BatchMatMulV3Advanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | namespace BatchMatMulV3Advanced { | 22 | namespace BatchMatMulV3Advanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -31,7 +31,6 @@ | |||
| 31 | 31 | ||
| 32 | 32 | ||
| 33 | 33 | ||
| 34 | -// #include "kernel_operator.h" | ||
| 35 | using namespace std; | 34 | using namespace std; |
| 36 | 35 | ||
| 37 | class batch_mat_mul_v3_test : public testing::Test { | 36 | class batch_mat_mul_v3_test : public testing::Test { |
| @@ -21,7 +21,7 @@ | |||
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| 24 | -#include "kernel_operator_intf.h" | 24 | +#include "kernel_basic_intf.h" |
| 25 | 25 | ||
| 26 | 26 | ||
| 27 | 27 | ||
| @@ -22,7 +22,7 @@ | |||
| 22 | 22 | ||
| 23 | 23 | ||
| 24 | 24 | ||
| 25 | -#include "kernel_operator.h" | 25 | +#include "kernel_basic_intf.h" |
| 26 | 26 | ||
| 27 | 27 | ||
| 28 | namespace Cmct::Gemm::Block { | 28 | namespace Cmct::Gemm::Block { |
| @@ -20,7 +20,7 @@ | |||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | -#include "kernel_operator.h" | 23 | +#include "kernel_basic_intf.h" |
| 24 | 24 | ||
| 25 | 25 | ||
| 26 | 26 | ||
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | 22 | ||
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | 22 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | namespace Cmct { | 22 | namespace Cmct { |
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -15,7 +15,8 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | + | ||
| 19 | 20 | ||
| 20 | 21 | ||
| 21 | 22 | ||
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | 22 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -23,7 +23,7 @@ | |||
| 23 | 23 | ||
| 24 | 24 | ||
| 25 | 25 | ||
| 26 | -#include "kernel_operator.h" | 26 | +#include "kernel_basic_intf.h" |
| 27 | 27 | ||
| 28 | 28 | ||
| 29 | 29 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -15,8 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | - | ||
| 20 | 19 | ||
| 21 | 20 | ||
| 22 | 21 | ||
| @@ -280,4 +279,4 @@ __aicore__ inline void QuantMmBatchMX<QBMM_MX_KERNEL_FUN_TEM_PARAMS>::ProcessSin | |||
| 280 | } // namespace Gemm | 279 | } // namespace Gemm |
| 281 | } // namespace Cmct | 280 | } // namespace Cmct |
| 282 | 281 | ||
| 283 | -#endif | 282 | +#endif |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | 22 | ||
| @@ -10,7 +10,7 @@ | |||
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | -#include "kernel_operator_intf.h" | 13 | +#include "kernel_basic_intf.h" |
| 14 | 14 | ||
| 15 | 15 | ||
| 16 | namespace Cmct::Prologue { | 16 | namespace Cmct::Prologue { |
| @@ -10,7 +10,7 @@ | |||
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | -#include "kernel_operator_intf.h" | 13 | +#include "kernel_basic_intf.h" |
| 14 | namespace Cmct::Prologue::Tile { | 14 | namespace Cmct::Prologue::Tile { |
| 15 | 15 | ||
| 16 | using AscendC::MicroAPI::RegTensor; | 16 | using AscendC::MicroAPI::RegTensor; |
| @@ -9,7 +9,7 @@ | |||
| 9 | */ | 9 | */ |
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | -#include "kernel_operator_intf.h" | 12 | +#include "kernel_basic_intf.h" |
| 13 | 13 | ||
| 14 | 14 | ||
| 15 | 15 | ||
| @@ -11,7 +11,7 @@ | |||
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | 13 | ||
| 14 | -#include "kernel_operator_intf.h" | 14 | +#include "kernel_basic_intf.h" |
| 15 | namespace Cmct::Prologue::Tile { | 15 | namespace Cmct::Prologue::Tile { |
| 16 | using AscendC::MicroAPI::RegTensor; | 16 | using AscendC::MicroAPI::RegTensor; |
| 17 | using Gemm::BLK_ELEM; | 17 | using Gemm::BLK_ELEM; |
| @@ -10,7 +10,7 @@ | |||
| 10 | */ | 10 | */ |
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | -#include "kernel_operator_intf.h" | 13 | +#include "kernel_basic_intf.h" |
| 14 | 14 | ||
| 15 | 15 | ||
| 16 | 16 | ||
| @@ -10,7 +10,7 @@ | |||
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | -#include "kernel_operator_intf.h" | 13 | +#include "kernel_basic_intf.h" |
| 14 | 14 | ||
| 15 | 15 | ||
| 16 | namespace Cmct::Gemm::Tile { | 16 | namespace Cmct::Gemm::Tile { |
| @@ -17,7 +17,8 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | + | ||
| 21 | 22 | ||
| 22 | namespace Cmct { | 23 | namespace Cmct { |
| 23 | namespace Gemm { | 24 | namespace Gemm { |
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | namespace Cmct { | 19 | namespace Cmct { |
| 20 | namespace Gemm { | 20 | namespace Gemm { |
| 21 | 21 | ||
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | namespace Cmct { | 21 | namespace Cmct { |
| 22 | namespace Gemm { | 22 | namespace Gemm { |
| @@ -14,7 +14,7 @@ | |||
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | -#include "kernel_operator.h" | 17 | +#include "kernel_basic_intf.h" |
| 18 | 18 | ||
| 19 | namespace AscendC { | 19 | namespace AscendC { |
| 20 | namespace Std { | 20 | namespace Std { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -11,7 +11,7 @@ | |||
| 11 | 11 | ||
| 12 | 12 | ||
| 13 | 13 | ||
| 14 | -#include "kernel_operator_intf.h" | 14 | +#include "kernel_basic_intf.h" |
| 15 | 15 | ||
| 16 | namespace Cmct { | 16 | namespace Cmct { |
| 17 | template <typename T> | 17 | template <typename T> |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -9,7 +9,7 @@ | |||
| 9 | */ | 9 | */ |
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | -#include "kernel_operator.h" | 12 | +#include "kernel_basic_intf.h" |
| 13 | 13 | ||
| 14 | 14 | ||
| 15 | namespace Cmct::Gemm { | 15 | namespace Cmct::Gemm { |
| @@ -7,4 +7,4 @@ | |||
| 7 | # See LICENSE in the root of the software repository for the full text of the License. | 7 | # See LICENSE in the root of the software repository for the full text of the License. |
| 8 | #/ | 8 | #/ |
| 9 | 9 | ||
| 10 | -add_modules_sources(HOSTNAME ${OPHOST_NAME} MODE PRIVATE DIR ${CMAKE_CURRENT_SOURCE_DIR} OPTYPE common ACLNNTYPE aclnn_exclude) | 10 | +add_modules_sources(HOSTNAME ${OPHOST_NAME} MODE PRIVATE DIR ${CMAKE_CURRENT_SOURCE_DIR} OPTYPE common ACLNNTYPE aclnn_exclude DEPENDENCIES batch_mat_mul_v3) |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -19,7 +19,7 @@ | |||
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | -#include "kernel_operator.h" | 22 | +#include "kernel_basic_intf.h" |
| 23 | 23 | ||
| 24 | 24 | ||
| 25 | 25 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -19,6 +19,7 @@ | |||
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | + | ||
| 22 | 23 | ||
| 23 | 24 | ||
| 24 | 25 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -23,7 +23,8 @@ | |||
| 23 | 23 | ||
| 24 | 24 | ||
| 25 | 25 | ||
| 26 | -#include "kernel_operator.h" | 26 | +#include "kernel_basic_intf.h" |
| 27 | + | ||
| 27 | 28 | ||
| 28 | 29 | ||
| 29 | 30 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | using namespace AscendC; | 21 | using namespace AscendC; |
| 21 | using namespace matmul; | 22 | using namespace matmul; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | const uint64_t ND2NZ_AIV_SYNC_AIC_FLAG = 8; | 21 | const uint64_t ND2NZ_AIV_SYNC_AIC_FLAG = 8; |
| 21 | const uint64_t MAX_NUM = 12 * 1024; //ub最大容纳的元素个数 | 22 | const uint64_t MAX_NUM = 12 * 1024; //ub最大容纳的元素个数 |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | using namespace AscendC; | 21 | using namespace AscendC; |
| 21 | using namespace matmul; | 22 | using namespace matmul; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | using namespace AscendC; | 21 | using namespace AscendC; |
| 21 | using namespace matmul; | 22 | using namespace matmul; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | 21 | ||
| 21 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 19 | 20 | ||
| 20 | 21 | ||
| 21 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -13,6 +13,7 @@ | |||
| 13 | * \brief | 13 | * \brief |
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | + | ||
| 16 | 17 | ||
| 17 | 18 | ||
| 18 | 19 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -14,7 +14,8 @@ | |||
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | -#include "kernel_operator.h" | 17 | +#include "kernel_basic_intf.h" |
| 18 | + | ||
| 18 | 19 | ||
| 19 | 20 | ||
| 20 | 21 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,7 +16,6 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | - | ||
| 20 | 19 | ||
| 21 | 20 | ||
| 22 | 21 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,6 +15,8 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | + | ||
| 19 | + | ||
| 18 | 20 | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -30,7 +30,7 @@ | |||
| 30 | 30 | ||
| 31 | 31 | ||
| 32 | 32 | ||
| 33 | -#include "kernel_operator.h" | 33 | +#include "kernel_basic_intf.h" |
| 34 | 34 | ||
| 35 | 35 | ||
| 36 | 36 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,10 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | -#include "kernel_operator_intf.h" | 20 | +#include "quantization/ascend_dequant_utils.h" |
| 21 | + | ||
| 22 | + | ||
| 21 | 23 | ||
| 22 | 24 | ||
| 23 | 25 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | class QuantBatchMatmulV3BaseBlock { | 23 | class QuantBatchMatmulV3BaseBlock { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | 22 | ||
| 21 | 23 | ||
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,6 +16,8 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | + | ||
| 20 | + | ||
| 19 | 21 | ||
| 20 | namespace AscendC { | 22 | namespace AscendC { |
| 21 | 23 | ||
| @@ -22,7 +22,7 @@ | |||
| 22 | 22 | ||
| 23 | 23 | ||
| 24 | 24 | ||
| 25 | -#include "kernel_operator.h" | 25 | +#include "kernel_basic_intf.h" |
| 26 | 26 | ||
| 27 | 27 | ||
| 28 | 28 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | - #include "kernel_operator.h" | 19 | + #include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | using AscendC::AIC; | 22 | using AscendC::AIC; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -14,8 +14,7 @@ | |||
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | -#include "kernel_operator.h" | 17 | +#include "kernel_basic_intf.h" |
| 18 | - | ||
| 19 | // if run with ttk without bias, can't get DTYPE_BIAS macro | 18 | // if run with ttk without bias, can't get DTYPE_BIAS macro |
| 20 | 19 | ||
| 21 | 20 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,7 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,7 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | namespace TransposeBatchMatMulAdvanced { | 22 | namespace TransposeBatchMatMulAdvanced { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | using AscendC::MicroAPI::RegTensor; | 22 | using AscendC::MicroAPI::RegTensor; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -17,8 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | - | ||
| 22 | 21 | ||
| 23 | 22 | ||
| 24 | namespace WeightQuantBatchMatmulV2::Arch35 { | 23 | namespace WeightQuantBatchMatmulV2::Arch35 { |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | using AscendC::BLOCK_CUBE; | 22 | using AscendC::BLOCK_CUBE; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | using AscendC::VECTOR_REG_WIDTH; | 22 | using AscendC::VECTOR_REG_WIDTH; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | using AscendC::BLOCK_CUBE; | 22 | using AscendC::BLOCK_CUBE; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | using AscendC::BLOCK_CUBE; | 22 | using AscendC::BLOCK_CUBE; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -20,8 +20,7 @@ | |||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | -#include "kernel_operator.h" | 23 | +#include "kernel_basic_intf.h" |
| 24 | - | ||
| 25 | 24 | ||
| 26 | using AscendC::BLOCK_CUBE; | 25 | using AscendC::BLOCK_CUBE; |
| 27 | using AscendC::CacheMode; | 26 | using AscendC::CacheMode; |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -18,7 +18,7 @@ | |||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | -#include "kernel_operator.h" | 21 | +#include "kernel_basic_intf.h" |
| 22 | 22 | ||
| 23 | 23 | ||
| 24 | 24 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -19,8 +19,7 @@ | |||
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | 21 | ||
| 22 | -#include "kernel_operator.h" | 22 | +#include "kernel_basic_intf.h" |
| 23 | - | ||
| 24 | 23 | ||
| 25 | 24 | ||
| 26 | 25 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -25,7 +25,7 @@ | |||
| 25 | 25 | ||
| 26 | 26 | ||
| 27 | ((defined(DT_INT4) && ORIG_DTYPE_WEIGHT == DT_INT4) || (defined(DT_INT32) && ORIG_DTYPE_WEIGHT == DT_INT32)) | 27 | ((defined(DT_INT4) && ORIG_DTYPE_WEIGHT == DT_INT4) || (defined(DT_INT32) && ORIG_DTYPE_WEIGHT == DT_INT32)) |
| 28 | -#define S4 | 28 | +#define WQBMMV2_S4 |
| 29 | 29 | ||
| 30 | 30 | ||
| 31 | 31 | ||
| @@ -45,7 +45,7 @@ | |||
| 45 | 45 | ||
| 46 | 46 | ||
| 47 | 47 | ||
| 48 | -#define S8 | 48 | +#define WQBMMV2_S8 |
| 49 | 49 | ||
| 50 | 50 | ||
| 51 | 51 | ||
| @@ -244,7 +244,7 @@ ASCENDC_TPL_SEL( | |||
| 244 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 244 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 245 | ), | 245 | ), |
| 246 | 246 | ||
| 247 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 247 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 248 | ASCENDC_TPL_ARGS_SEL( | 248 | ASCENDC_TPL_ARGS_SEL( |
| 249 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 249 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 250 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 250 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -265,7 +265,7 @@ ASCENDC_TPL_SEL( | |||
| 265 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) | 265 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) |
| 266 | ), | 266 | ), |
| 267 | 267 | ||
| 268 | - #if !defined(__CCE_AICORE__) || ((defined(S4) || defined(F4)) && !defined(WEIGHT_ND)) | 268 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S4) || defined(F4)) && !defined(WEIGHT_ND)) |
| 269 | ASCENDC_TPL_ARGS_SEL( | 269 | ASCENDC_TPL_ARGS_SEL( |
| 270 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 270 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 271 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 271 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -286,7 +286,7 @@ ASCENDC_TPL_SEL( | |||
| 286 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) | 286 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) |
| 287 | ), | 287 | ), |
| 288 | 288 | ||
| 289 | - #if !defined(__CCE_AICORE__) || (defined(S4) && !defined(WEIGHT_ND)) | 289 | + #if !defined(__CCE_AICORE__) || (defined(WQBMMV2_S4) && !defined(WEIGHT_ND)) |
| 290 | ASCENDC_TPL_ARGS_SEL( | 290 | ASCENDC_TPL_ARGS_SEL( |
| 291 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 291 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 292 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 292 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -307,7 +307,7 @@ ASCENDC_TPL_SEL( | |||
| 307 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 307 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 308 | ), | 308 | ), |
| 309 | 309 | ||
| 310 | - #if !defined(__CCE_AICORE__) || (defined(S4) && !defined(WEIGHT_ND)) | 310 | + #if !defined(__CCE_AICORE__) || (defined(WQBMMV2_S4) && !defined(WEIGHT_ND)) |
| 311 | ASCENDC_TPL_ARGS_SEL( | 311 | ASCENDC_TPL_ARGS_SEL( |
| 312 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 312 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 313 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 313 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -328,7 +328,7 @@ ASCENDC_TPL_SEL( | |||
| 328 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 328 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 329 | ), | 329 | ), |
| 330 | 330 | ||
| 331 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 331 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 332 | ASCENDC_TPL_ARGS_SEL( | 332 | ASCENDC_TPL_ARGS_SEL( |
| 333 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 333 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 334 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 334 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -349,7 +349,7 @@ ASCENDC_TPL_SEL( | |||
| 349 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 349 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 350 | ), | 350 | ), |
| 351 | 351 | ||
| 352 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(WEIGHT_F8_INPUT) || defined(S4)) && defined(WEIGHT_ND)) | 352 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 353 | ASCENDC_TPL_ARGS_SEL( | 353 | ASCENDC_TPL_ARGS_SEL( |
| 354 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 354 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 355 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 355 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -370,7 +370,7 @@ ASCENDC_TPL_SEL( | |||
| 370 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 370 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 371 | ), | 371 | ), |
| 372 | 372 | ||
| 373 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 373 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 374 | ASCENDC_TPL_ARGS_SEL( | 374 | ASCENDC_TPL_ARGS_SEL( |
| 375 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 375 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 376 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 376 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -391,7 +391,7 @@ ASCENDC_TPL_SEL( | |||
| 391 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 391 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 392 | ), | 392 | ), |
| 393 | 393 | ||
| 394 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(WEIGHT_F8_INPUT) || defined(S4)) && defined(WEIGHT_ND)) | 394 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 395 | ASCENDC_TPL_ARGS_SEL( | 395 | ASCENDC_TPL_ARGS_SEL( |
| 396 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 396 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 397 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 397 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -474,7 +474,7 @@ ASCENDC_TPL_SEL( | |||
| 474 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 474 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 475 | ), | 475 | ), |
| 476 | 476 | ||
| 477 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 477 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 478 | ASCENDC_TPL_ARGS_SEL( | 478 | ASCENDC_TPL_ARGS_SEL( |
| 479 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 479 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 480 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 480 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -495,7 +495,7 @@ ASCENDC_TPL_SEL( | |||
| 495 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) | 495 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) |
| 496 | ), | 496 | ), |
| 497 | 497 | ||
| 498 | - #if !defined(__CCE_AICORE__) || ((defined(S4) || defined(F4)) && !defined(WEIGHT_ND)) | 498 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S4) || defined(F4)) && !defined(WEIGHT_ND)) |
| 499 | ASCENDC_TPL_ARGS_SEL( | 499 | ASCENDC_TPL_ARGS_SEL( |
| 500 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 500 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 501 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 501 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -516,7 +516,7 @@ ASCENDC_TPL_SEL( | |||
| 516 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) | 516 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2RegBaseTilingDataParams) |
| 517 | ), | 517 | ), |
| 518 | 518 | ||
| 519 | - #if !defined(__CCE_AICORE__) || (defined(S4) && !defined(WEIGHT_ND)) | 519 | + #if !defined(__CCE_AICORE__) || (defined(WQBMMV2_S4) && !defined(WEIGHT_ND)) |
| 520 | ASCENDC_TPL_ARGS_SEL( | 520 | ASCENDC_TPL_ARGS_SEL( |
| 521 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 521 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 522 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 522 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -537,7 +537,7 @@ ASCENDC_TPL_SEL( | |||
| 537 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 537 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 538 | ), | 538 | ), |
| 539 | 539 | ||
| 540 | - #if !defined(__CCE_AICORE__) || (defined(S4) && !defined(WEIGHT_ND)) | 540 | + #if !defined(__CCE_AICORE__) || (defined(WQBMMV2_S4) && !defined(WEIGHT_ND)) |
| 541 | ASCENDC_TPL_ARGS_SEL( | 541 | ASCENDC_TPL_ARGS_SEL( |
| 542 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 542 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 543 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 543 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -558,7 +558,7 @@ ASCENDC_TPL_SEL( | |||
| 558 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 558 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 559 | ), | 559 | ), |
| 560 | 560 | ||
| 561 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 561 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 562 | ASCENDC_TPL_ARGS_SEL( | 562 | ASCENDC_TPL_ARGS_SEL( |
| 563 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 563 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 564 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 564 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -579,7 +579,7 @@ ASCENDC_TPL_SEL( | |||
| 579 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 579 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 580 | ), | 580 | ), |
| 581 | 581 | ||
| 582 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(WEIGHT_F8_INPUT) || defined(S4)) && defined(WEIGHT_ND)) | 582 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 583 | ASCENDC_TPL_ARGS_SEL( | 583 | ASCENDC_TPL_ARGS_SEL( |
| 584 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 584 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 585 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 585 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -601,7 +601,7 @@ ASCENDC_TPL_SEL( | |||
| 601 | ), | 601 | ), |
| 602 | 602 | ||
| 603 | 603 | ||
| 604 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(S4)) && defined(WEIGHT_ND)) | 604 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 605 | ASCENDC_TPL_ARGS_SEL( | 605 | ASCENDC_TPL_ARGS_SEL( |
| 606 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 606 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 607 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 607 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -622,7 +622,7 @@ ASCENDC_TPL_SEL( | |||
| 622 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) | 622 | ASCENDC_TPL_TILING_STRUCT_SEL(wqbmmv2_tiling::WeightQuantBatchMatmulV2ASTilingDataParams) |
| 623 | ), | 623 | ), |
| 624 | 624 | ||
| 625 | - #if !defined(__CCE_AICORE__) || ((defined(S8) || defined(WEIGHT_F8_INPUT) || defined(S4)) && defined(WEIGHT_ND)) | 625 | + #if !defined(__CCE_AICORE__) || ((defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(WQBMMV2_S4)) && defined(WEIGHT_ND)) |
| 626 | ASCENDC_TPL_ARGS_SEL( | 626 | ASCENDC_TPL_ARGS_SEL( |
| 627 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), | 627 | ASCENDC_TPL_KERNEL_TYPE_SEL(ASCENDC_TPL_MIX_AIC_1_2), |
| 628 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), | 628 | ASCENDC_TPL_UINT_SEL(SOC_VERSION_TYPE, ASCENDC_TPL_UI_LIST, WQBMMV2_SOC_SUPPORT_L1_TO_BT_BF16), |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,8 +15,7 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | - | ||
| 20 | 19 | ||
| 21 | 20 | ||
| 22 | 21 | ||
Mmatmul/weight_quant_batch_matmul_v2/op_kernel/arch35/weight_quant_batch_matmul_v2_reg_base_common.h+2-3
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -16,8 +16,7 @@ | |||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | -#include "kernel_operator.h" | 19 | +#include "kernel_basic_intf.h" |
| 20 | - | ||
| 21 | 20 | ||
| 22 | namespace MicroAPI = AscendC::MicroAPI; | 21 | namespace MicroAPI = AscendC::MicroAPI; |
| 23 | 22 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -17,7 +17,7 @@ | |||
| 17 | 17 | ||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | -#include "kernel_operator.h" | 20 | +#include "kernel_basic_intf.h" |
| 21 | 21 | ||
| 22 | 22 | ||
| 23 | 23 | ||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -18,6 +18,8 @@ | |||
| 18 | 18 | ||
| 19 | 19 | ||
| 20 | 20 | ||
| 21 | + | ||
| 22 | + | ||
| 21 | 23 | ||
| 22 | defined(ORIG_DTYPE_ANTIQUANT_SCALE) && \ | 24 | defined(ORIG_DTYPE_ANTIQUANT_SCALE) && \ |
| 23 | ((ORIG_DTYPE_ANTIQUANT_SCALE == DT_UINT64) || (ORIG_DTYPE_ANTIQUANT_SCALE == DT_INT64))) | 25 | ((ORIG_DTYPE_ANTIQUANT_SCALE == DT_UINT64) || (ORIG_DTYPE_ANTIQUANT_SCALE == DT_INT64))) |
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | - * Copyright (c) 2025 Huawei Technologies Co., Ltd. | 2 | + * Copyright (c) 2025-2026 Huawei Technologies Co., Ltd. |
| 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of | 3 | * This program is free software, you can redistribute it and/or modify it under the terms and conditions of |
| 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). | 4 | * CANN Open Software License Agreement Version 2.0 (the "License"). |
| 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. | 5 | * Please refer to the License for details. You may not use this file except in compliance with the License. |
| @@ -15,20 +15,19 @@ | |||
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | -#include "kernel_operator.h" | 18 | +#include "kernel_basic_intf.h" |
| 19 | - | ||
| 20 | 19 | ||
| 21 | 20 | ||
| 22 | 21 | ||
| 23 | 22 | ||
| 24 | 23 | ||
| 25 | -#if defined(A16) && (defined(S4) || defined(F4) || defined(S8)) | 24 | +#if defined(A16) && (defined(WQBMMV2_S4) || defined(F4) || defined(WQBMMV2_S8)) |
| 26 | 25 | ||
| 27 | 26 | ||
| 28 | 27 | ||
| 29 | 28 | ||
| 30 | 29 | ||
| 31 | -#if defined(A16) && (defined(S4) || defined(S8) || defined(WEIGHT_F8_INPUT) || defined(MICROSCALING)) | 30 | +#if defined(A16) && (defined(WQBMMV2_S4) || defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(MICROSCALING)) |
| 32 | 31 | ||
| 33 | using WeightQuantBatchMatmulV2::InvokeKernel; | 32 | using WeightQuantBatchMatmulV2::InvokeKernel; |
| 34 | 33 | ||
| @@ -116,13 +115,13 @@ __global__ __aicore__ void weight_quant_batch_matmul_v2( | |||
| 116 | using DtypeBias = AscendC::Std::conditional_t<IS_BIAS_FP32, float, DTYPE_X>; | 115 | using DtypeBias = AscendC::Std::conditional_t<IS_BIAS_FP32, float, DTYPE_X>; |
| 117 | static constexpr QuantType antiquantType = static_cast<QuantType>(ANTIQUANT_TYPE); | 116 | static constexpr QuantType antiquantType = static_cast<QuantType>(ANTIQUANT_TYPE); |
| 118 | if constexpr (SUB_ALGORITHM == WQBMMV2_SUB_ALGO_ANTI_REG_SCSC) { | 117 | if constexpr (SUB_ALGORITHM == WQBMMV2_SUB_ALGO_ANTI_REG_SCSC) { |
| 119 | -#if defined(A16) && (defined(S4) || defined(F4) || defined(S8)) | 118 | +#if defined(A16) && (defined(WQBMMV2_S4) || defined(F4) || defined(WQBMMV2_S8)) |
| 120 | INVOKE_WEIGHT_QUANT_BMM_OP_REG_BASE_IMPL( | 119 | INVOKE_WEIGHT_QUANT_BMM_OP_REG_BASE_IMPL( |
| 121 | DtypeBias, WeightQuantBatchMatmulV2RegBaseKernel, TRANS_A, TRANS_B, HAS_ANTIQUANT_OFFSET, antiquantType, | 120 | DtypeBias, WeightQuantBatchMatmulV2RegBaseKernel, TRANS_A, TRANS_B, HAS_ANTIQUANT_OFFSET, antiquantType, |
| 122 | IS_WEIGHT_NZ); | 121 | IS_WEIGHT_NZ); |
| 123 | 122 | ||
| 124 | } else { | 123 | } else { |
| 125 | -#if defined(A16) && (defined(S4) || defined(S8) || defined(WEIGHT_F8_INPUT) || defined(MICROSCALING)) | 124 | +#if defined(A16) && (defined(WQBMMV2_S4) || defined(WQBMMV2_S8) || defined(WEIGHT_F8_INPUT) || defined(MICROSCALING)) |
| 126 | InvokeKernel< | 125 | InvokeKernel< |
| 127 | TEMPLATE_CUSTOM, TRANS_A, TRANS_B, ANTIQUANT_TYPE, HAS_ANTIQUANT_OFFSET, IS_BIAS_FP32, IS_WEIGHT_NZ>( | 126 | TEMPLATE_CUSTOM, TRANS_A, TRANS_B, ANTIQUANT_TYPE, HAS_ANTIQUANT_OFFSET, IS_BIAS_FP32, IS_WEIGHT_NZ>( |
| 128 | KERNEL_PARAMS); | 127 | KERNEL_PARAMS); |