Skip to content

[Operator Mechanism] Refine depthwise conv int conversion #79258

Open
feixi139 wants to merge 11 commits into
PaddlePaddle:developfrom
feixi139:split-depthwise-conv-change
Open

[Operator Mechanism] Refine depthwise conv int conversion #79258
feixi139 wants to merge 11 commits into
PaddlePaddle:developfrom
feixi139:split-depthwise-conv-change

Conversation

@feixi139

@feixi139 feixi139 commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

PR Category

Operator Mechanism

PR Types

Bug fixes

Description

本 PR 拆分并整理 conv 相关文件中的整型溢出修复,主要处理大 Tensor 场景下 int * intint64_t = int32_t、以及 CUDA launch 参数窄化等问题。

主要修改包括:

  • 修复 conv / depthwise conv 相关 CUDA kernel 中 int * int 在结果提升到 int64_t 前已经发生 int32 溢出的问题。
  • 修复 tensor size、shape product、stride、offset 等中间值从 int64_t 被错误收窄到 int 的问题。
  • 对必须传入 int 参数的 kernel/API 边界增加 INT_MAX 检查,避免静默截断。
  • 对 CUDA launch 的 grid / block 等 uint32 边界增加 UINT32_MAX 检查,避免 launch 配置溢出。
  • 将 gpudnn conv runner 中仅用于 pointer arithmetic 的 group offset 保持为 int64_t,避免不必要的 int32 限制。
  • 清理 depthwise conv 相关分支中由冲突合入引入的冗余赋值和不一致类型转换。

是否引起精度变化

PaddlePaddle-bot

This comment was marked as outdated.

@PaddlePaddle-bot

PaddlePaddle-bot commented Jun 5, 2026

Copy link
Copy Markdown

🤖 Paddle-CI-Agent | ci_status_monitor | 2026-06-22 13:11:41 UTC+08:00

CI报告基于以下代码生成(30分钟更新一次):
PR commit: 030cdeb | Merge base: c87be77 (branch: develop)


1 Required任务 : 36/47 通过

总执行(rerun次数) 总任务 ✅ 通过 ❌ 失败 ⏳ 运行中 ⏸️ 等待中 跳过
79(0) 79 67 2 4 0 6
任务 错误类型 置信度 日志
Coverage clone / Clone Paddle 环境问题 Job
Check approval 需要 Approval Job

2 失败详情

🔴 Coverage clone / Clone Paddle — 环境问题(置信度: 高)

分析器: 通用分析(fallback)
失败用例: 无(Clone paddle 步骤失败)

用例 错误摘要
Clone paddle actions/checkout@v6 执行 recursive submodule update 时,third_party/openvino/thirdparty/open_model_zooshallow.lock 已存在,导致 submodule fetch 失败

关键日志:

fatal: Unable to create .../open_model_zoo/shallow.lock: File exists.
Another git process seems to be running in this repository...
Unable to fetch in submodule path 'third_party/openvino/thirdparty/open_model_zoo'
fatal: Fetched in submodule path 'third_party/openvino/thirdparty/open_model_zoo', but it did not contain e7df86da686d2e1600282422e54f66c2fecea160.
  • 根因摘要: Runner 残留 git 锁导致 submodule 克隆失败
    失败发生在 Clone paddle 阶段,后续 Merge PR to test branch 未执行。日志明确指向 runner 工作目录中的 .git/modules/.../shallow.lock 已存在,属于 checkout/submodule 环境状态异常,不是本 PR 的代码逻辑引起。

修复建议:

  1. 环境问题,请 rerun;若复现,需清理 runner workspace 中残留的 third_party/openvino/.../open_model_zoo/shallow.lock 或重置该 runner 工作目录后重试。

关联变更: 无(失败发生在合并 PR 前的 Clone paddle 步骤)

🔴 Check approval — 需要 Approval(置信度: 高)

该 Job 需要人工 Approval,完成审批后 CI 才会继续执行。

  • 根因摘要: 需要人工审批
  • 修复建议: 请通过人工审批
  • 关联变更: 无

@paddle-bot paddle-bot Bot added the contributor External developers label Jun 5, 2026
PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

fix bugs

fix bugs

fix bugs

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

fix bugs

fix bugs
@feixi139 feixi139 force-pushed the split-depthwise-conv-change branch from ecce61e to 14d88ce Compare June 12, 2026 05:14
PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

PaddlePaddle-bot

This comment was marked as outdated.

@feixi139

Copy link
Copy Markdown
Contributor Author

/re-run all-failed

@PaddlePaddle-bot PaddlePaddle-bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Paddle-CI-Agent | pr_review | 2026-06-22 11:49:07

📋 Review 摘要

PR 概述:拆分整理 depthwise conv / gpudnn conv 的大 Tensor 整数溢出和 launch 边界检查。
变更范围paddle/phi/kernels/gpu/paddle/phi/kernels/gpudnn/、CUTLASS conv2d util
影响面 TagOperator Mechanism

问题

未发现阻塞性问题。PR 规范问题在下面章节报,不要在这里重复

历史 Findings 修复情况

Finding 问题 状态
F1 ConvRunner::Apply 的 group offset 参数拓宽后调用点仍可能先用 int 溢出 ✅ 已修复

📝 PR 规范检查

符合规范。PR Category Operator Mechanism、PR Types Bug fixes、精度变化 均已填写,描述清晰完整。

总体评价

本轮重点回溯了 9 个变更文件中 int64_t 索引提升、int 边界检查、CUDA grid/block launch 配置,以及 gpudnn group offset 的调用链。当前 diff 未确认到需要阻塞合入的新问题;历史 group offset finding 在当前代码中已由 int64_t group_offset_* 计算和传参覆盖。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contributor External developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants