已关闭
[Bug-Report|缺陷反馈]: ActULQClampMaxGrad算子缺乏Kernel调用场景下的异常校验 #4717
Nerddddddddddd创建于  8月11日关闭于  8月13日
Nerddddddddddd
Nerddddddddddd成员
8月11日 创建

Thanks for sending an issue! Please fill in the following template to help quickly solve your problem.

Describe the current behavior / 问题描述 (Mandatory / 必填)

mask/x_clamped_loss dtype 校验与 dtype 组合联动拦截不到位,需要新增

Environment / 环境信息 (Mandatory / 必填)

Ascend950

Steps to reproduce the issue / 重现步骤 (Mandatory / 必填)

TilingFunc GetShapeAndDtype 原仅校验 y_grad dtype,mask/x_clamped_loss dtype
及 dtype 组合合法性未校验,非法 dtype(如 mask=int32)和非法组合(如
fp16/fp32/fp16)经 PrecisionReduceFlag Cast 后可绕过约束进入 kernel。

增补:

  • clamp_max_mask dtype 校验:∈ {bool, fp16, fp32}
  • x_clamped_loss dtype 校验:∈ {fp16, fp32}
  • dtype 组合联动校验:mask 浮点型→三输入同型;mask bool→y_grad==x_clamped_loss
    (对应 def.cpp 4 列合法 profile)

Describe the expected behavior / 预期结果 (Mandatory / 必填)

TTK kernel 模式 Ascend950 实跑验证:3 个应拦截未拦截 probe 转为 INVALID_TILING
有效拦截,2 个合法 control 仍 PASS。

无

Special notes for this issue/备注 (Optional / 选填)

likedislike
NerdddddddddddNerddddddddddd成员
8月11日 添加了label:bug-report
yuning_chenyuning_chen成员
8月11日 将 Coder_Nerd 设为负责人
NerdddddddddddNerddddddddddd成员
8月13日 issue状态由 进行中 改变为 已解决
NerdddddddddddNerddddddddddd成员
8月13日 关闭了 issue