已合并
问题修复:ExtendConvTranspose算子修复A16W8场景下部分case AIC问题 #8626
sunlesheng创建于 13 天前
问题修复:ExtendConvTranspose算子修复A16W8场景下部分case AIC问题 #8626
已合并
sunlesheng创建于 13 天前
sunlesheng
sunlesheng
13 天前

描述

问题修复:ExtendConvTranspose算子A16W8场景下部分caseTiling计算时因为开启pingpong后,压缩K轴,但K轴需要32对齐,导致L0A空间溢出,AIC_ERROR异常

关联的Issue

https://gitcode.com/cann/ops-nn/issues/4874

测试

RDV、compile通过

文档更新

不涉及

类型标签

AI/Agent生成声明

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 sunlesheng 的贡献)
sunleshengsunlesheng
13 天前 创建了 pull request,commit bcf019bf
atomgit-bot
atomgit-bot
13 天前 评论:

变更摘要

该 PR 针对 A16W8 场景下部分 case 的 AIC 问题进行修复,核心改动位于 conv3d_backprop_input_v2_small_kernel_tiling.cppConv3DDXV2SmallKernelTiling::InitBaseMNK 函数。此前当 kIter >= TWO_U32 时,会无条件开启 L0A/L0B 的 double buffer(DB_ON)并调用 calcMaxBaseK();本次改动在开启 DB 前新增容量校验,只有在开启 DB 后 L0A/L0B 仍能容纳 k0 时才真正启用 DB,避免 calcMaxBaseK() 内部强制对齐 k0 导致 L0 溢出。

主要改动

  • 新增开启 DB 前的容量校验逻辑: 在 InitBaseMNK 中根据 platformInfo_.l0_ab_sizeDB_ONdtypeByteL0a_dtypeByteL0b_l0Params.baseMl0Params.baseN 分别计算 maxBaseKByL0aDbmaxBaseKByL0bDb,用于评估 DB 开启后 L0A/L0B 可容纳的最大 K 值。
  • 将无条件开启 DB 改为条件开启: 仅当 maxBaseKByL0aDb >= tilingRunInfo_.k0maxBaseKByL0bDb >= tilingRunInfo_.k0 时,才设置 l0Params.al0Pbuffer = DB_ONl0Params.bl0Pbuffer = DB_ON 并调用 calcMaxBaseK()
  • 避免 L0 溢出: 当 DB 后 L0A/L0B 容量不足以容纳 k0 时,不再强制开启 DB,从而规避 calcMaxBaseK() 内强制对齐 k0 引发的 L0 溢出问题。
likedislike
atomgit-bot
atomgit-bot
13 天前 评论:

代码审查

✅ 未发现问题

likedislike
CANN-robotCANN-robot成员
13 天前 添加了label:cann-cla/yes
CANN-robot
CANN-robot成员
13 天前 评论:

Thanks for your pull-request.
The full list of commands accepted by me can be found at here.
You can get sig-info at here.
For more, you also can visit HICANN.


PR Approval Progress

Congratulations! All modules have met the lgtm and approve requirements.

Module Approval Details

module lgtm status approve status
conv 余鑫, 高成, 唐玮玮, 沈承宗 (4/2) 余鑫 (1/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)

CLA Signature Pass

sunlesheng, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robotCANN-robot成员
13 天前 将zengjuan,cheng_gao,chaotang233,crystalhu,yangyang016,fanqirui,chenqi317,lileizheng,liubo75,LiuZonggu,tangweiwei2,pingchuantang,wangcimeng,huafeng793,shenchengzong,yuxin5设为评审人
CANN-robotCANN-robot成员
13 天前 将cheng_gao,lileizheng,LiuZonggu,wangcimeng,huafeng793,shenchengzong,yuxin5设为审查人
sunlesheng
sunlesheng
12 天前 评论:

/compile

likedislike
sunleshengsunlesheng
12 天前 update merge request[project id: 7665709, iid: 8626, commit_id: b33bb73d1556de547e0cadae393dd39228e3897a] virtual merging success
CANN-robotCANN-robot成员
12 天前 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
12 天前 评论:

流水线任务触发成功
任务链接 [3b8f52de50f34aaab2bd3a2b69bfa997][流水线指导]

任务名称状态日志下载链接
Compile_Ascend_X86_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
Compile_Pre ✅ SUCCESS >>>>>
pre_comment ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910b ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910c ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_950 ✅ SUCCESS >>>>> >>>>>
Compile_classify ✅ SUCCESS >>>>>
Compile_Ascend_X86_mobile_station_9030_ubuntu24 ✅ SUCCESS >>>>> >>>>>
UT_Test_ophost ✅ SUCCESS
UT_Test_opapi ✅ SUCCESS
UT_Test_kernel ✅ SUCCESS
UT_Test_opgraph ✅ SUCCESS
PreSmoke_A900 ✅ SUCCESS >>>>>
API_Check ✅ SUCCESS >>>>>
PreSmoke_ATK_Test_A2 ✅ SUCCESS >>>>>
UT_Test_report_lcov ✅ SUCCESS >>>>>

[2026-08-14 11:51:21]    CI执行结束

likedislike
CANN-robot
CANN-robot成员
12 天前 评论:

流水线任务触发成功
任务链接 [b8456b3ab47f4020903861c2cbd7fc8f][流水线指导]

任务名称状态日志下载链接
antipoison ✅ SUCCESS >>>>>
codecheck_checkpr ✅ SUCCESS
StaticCheck_codespell ✅ SUCCESS
StaticCheck_link_validity ✅ SUCCESS
StaticCheck_resource_existence ✅ SUCCESS
StaticCheck_tag_closed ✅ SUCCESS
StaticCheck_markdownlint ✅ SUCCESS
codecheck_precommit ✅ SUCCESS >>>>>
SCA ✅ SUCCESS >>>>>

[2026-08-14 11:38:20]    CI执行结束

likedislike
CANN-robotCANN-robot成员
12 天前 添加了label:api-check-pass
CANN-robotCANN-robot成员
12 天前 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
12 天前 添加了label:ci-pipeline-passed
lileizheng成员
12 天前 评论:

/reject

likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:10:49Start_PipelineMR_398
likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:13:32Sync_PR :white_check_mark: 成功I17f5c1295d283f2c00ac9bbba7f98ee0247f4186
likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:13:53Trigger_SC :white_check_mark: 触发成功I17f5c1295d283f2c00ac9bbba7f98ee0247f418620260814_121832099
likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:38:20SC_Result :x: 失败I17f5c1295d283f2c00ac9bbba7f98ee0247f4186
likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:39:44CMETRICS :white_check_mark: 成功I17f5c1295d283f2c00ac9bbba7f98ee0247f4186
likedislike
conv2d_ci
12 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-14 12:40:04Trigger_RDV :white_check_mark: 触发成功I17f5c1295d283f2c00ac9bbba7f98ee0247f418620260814_124443027
likedislike
sunleshengsunlesheng
12 天前 修改标题为 “问题修复:修复A16W8场景下部分case AIC问题”,原标题为“修复A16W8场景下部分case AIC问题”
sunleshengsunlesheng
12 天前 修改标题为 “问题修复:ExtendConvTranspose算子修复A16W8场景下部分case AIC问题”,原标题为“问题修复:修复A16W8场景下部分case AIC问题”
conv2d_ci
11 天前 评论:
pipeline history
TimeNameResultChangeidTimeStamp
2026-08-15 12:40:31commit2026-08-13T10:48:48+08:00c113ab1d
SC_Result :x: FAILUREI17f5c12
RDV_Result :x: RUNNINGI17f5c12
本次未执行的rdv任务为
序号任务名未执行理由
1tbe该组的RDV疑似不需要运行:[1951DC, 1951MDC, rdv_tbe_1971_01, rdv_tbe_1981_01, rdv_tbe_1951dc_01, Smoke_1951lite, Smoke_1911mdc, rdv_tbe_1971_02, rdv_tbe_1911rc_01, rdv_tbe_1911ep_01, Smoke_davinci_rdv_Nano, Smoke_nanoc11, rdv_tbe_1952_01]
2David该组的RDV疑似不需要运行:[rdv_tbe_david_01, rdv_tbe_david_02, rdv_tbe_david_03]
3transpose该组的RDV疑似不需要运行:[Davinci_RDV_conv_back_V121, conv_backward_1982_rdv, conv_backward_1971_rdv, conv_transpose_1952_rdv]
likedislike
sunleshengsunlesheng
8 天前 修改了pull request 的描述
cheng_gao
cheng_gao成员
8 天前 评论:

/lgtm

likedislike
tangweiwei2成员
8 天前 评论:

/lgtm

likedislike
CANN-robotCANN-robot成员
8 天前 添加了label:lgtm
shenchengzong成员8 天前进行代码检视2
conv/conv3d_backprop_input_v2/op_host/op_tiling/arch35/conv3d_backprop_input_v2_small_kernel_tiling.cpp
@@ -112,3 +112,1 @@
112- l0Params.al0Pbuffer = DB_ON;
113- l0Params.bl0Pbuffer = DB_ON;
114- l0Params.baseK = calcMaxBaseK();
112+ // 开启DB前校验: DB后L0a/L0b至少需容纳k0, 否则calcMaxBaseK内强制对齐k0会导致L0溢出
shenchengzong8 天前评论:

还会有容纳不下k0的情况吗?

likedislike
sunlesheng
sunlesheng
7 天前 评论:

因为baseM是先调整的,preload是后确定的,调整完后重新计算baseK,如果前面baseM偏大,baseK最小只能调整到32,这个时候就会超

Sshenchengzong成员
7 天前 解决了最后一个问题
shenchengzong成员
7 天前 评论:

/lgtm

likedislike
yuxin5成员
7 天前 评论:

/approve

likedislike
CANN-robotCANN-robot成员
7 天前 添加了label:approved
CANN-robotCANN-robot成员
7 天前 删除了label:ci-pipeline-passed
CANN-robot
CANN-robot成员
7 天前 评论:

The following label is not ready.

ci-pipeline-passed: The ci-pipeline-passed label is expired as added over 72 hours. Please use /compile to recompile.

likedislike
sunlesheng
sunlesheng
7 天前 评论:

compile

likedislike
sunleshengsunlesheng
7 天前 update merge request[project id: 7665709, iid: 8626, commit_id: 4f387b58846e34c03ac511e4cd2520ec1798df0a] virtual merging success
CANN-robotCANN-robot成员
7 天前 删除了label:api-check-pass
CANN-robotCANN-robot成员
7 天前 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
7 天前 评论:

流水线任务触发成功
任务链接 [8d27427c61e64bec97b5a6ab7ff58d86][流水线指导]

任务名称状态日志下载链接
Compile_Ascend_X86_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
Compile_Pre ✅ SUCCESS >>>>>
pre_comment ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950_ubuntu24 ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910b ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_910c ✅ SUCCESS >>>>> >>>>>
Compile_X86_monitor_950 ✅ SUCCESS >>>>> >>>>>
Compile_classify ✅ SUCCESS >>>>>
Compile_Ascend_X86_mobile_station_9030_ubuntu24 ✅ SUCCESS >>>>> >>>>>
UT_Test_ophost ✅ SUCCESS
UT_Test_opapi ✅ SUCCESS
UT_Test_kernel ✅ SUCCESS
UT_Test_opgraph ✅ SUCCESS
PreSmoke_A900 ✅ SUCCESS >>>>>
API_Check ✅ SUCCESS >>>>>
PreSmoke_ATK_Test_A2 ✅ SUCCESS >>>>>
UT_Test_report_lcov ✅ SUCCESS >>>>>

[2026-08-19 10:01:24]    CI执行结束

likedislike
CANN-robot
CANN-robot成员
7 天前 评论:

流水线任务触发成功
任务链接 [850bfc366b544043b5ca06ea2ba76557][流水线指导]

任务名称状态日志下载链接
antipoison ✅ SUCCESS >>>>>
codecheck_checkpr ✅ SUCCESS
StaticCheck_codespell ✅ SUCCESS
StaticCheck_link_validity ✅ SUCCESS
StaticCheck_resource_existence ✅ SUCCESS
StaticCheck_tag_closed ✅ SUCCESS
StaticCheck_markdownlint ✅ SUCCESS
codecheck_precommit ✅ SUCCESS >>>>>
SCA ✅ SUCCESS >>>>>

[2026-08-19 09:49:32]    CI执行结束

likedislike
CANN-robotCANN-robot成员
7 天前 添加了label:api-check-pass
CANN-robotCANN-robot成员
7 天前 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
7 天前 添加了label:ci-pipeline-passed
CANN-robotCANN-robot成员
7 天前 关闭了关联的issue
CANN-robotCANN-robot成员
7 天前 合入了pull request
CANN-robot
CANN-robot成员
7 天前 评论:

Pull Request 已合并或已关闭。

If you want to solve this problem, you can click here to do it in the FAQs.

likedislike