external-cannbot-ops-ascendc-crash-debug
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "external-cannbot-ops-ascendc-crash-debug" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-f1e2bcb86b5e4d531da31f7375d7ac28e9dceeeafc3390b04e9d74e6ed6664ab. Verify the upstream source and version against https://github.com/ascend-ai-coding/awesome-ascend-skills before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
github.com
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
This skill is for debugging Ascend C operators that hang or crash, addressing scenarios where the program cannot complete, including: (1) program hangs/suspends/timeouts with unresponsive kernels, and (2) program crashes (segmentation faults).
Introduction source: third_party · ascend-ai-coding · 0.0.1 Reference
SkillPi interpretation
- Tasks
- Translation pending; see source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: external-cannbot-ops-ascendc-crash-debug
description: Ascend C 算子卡死/崩溃调试技能。用于处理程序无法运行完的场景:(1) 程序卡死/挂起/超时,Kernel 无响应,(2) 程序崩溃(Segmentation
Fault、Abort),(3) Buffer 冲突/死锁导致的核心挂起,(4) 需要解析 plog 日志定位卡死/崩溃位置。触发关键词:卡死、挂起、超时、崩溃、hang、crash、deadlock、Segmentation
Fault、Abort、Kernel hang、内存越界、plog。
original-name: ascendc-crash-debug
synced-from: https://gitcode.com/cann/cannbot-skills
synced-date: '2026-05-26'
synced-commit: ac5bbd2b4cf427d011874e11f8d1e8b1bef66eda
license: UNKNOWNAscend C 算子卡死/崩溃调试
系统化调试 Ascend C 算子无法运行完的问题,包括程序卡死/挂起、Kernel超时、程序崩溃。
快速诊断
程序无法运行完
│
├─ 程序崩溃?
│ ├─ 启用 coredump → ulimit -c unlimited
│ ├─ 生成 core 文件 → 运行程序
│ └─ GDB 分析 → gdb <exe> <core> → bt / bt full / info locals
│
└─ 程序卡死?
├─ 查看 plog 日志 → 定位卡死位置
├─ 检查 Buffer 配对 → AllocTensor/FreeTensor
├─ 检查同步 → EnQue/DeQue 配对
└─ Kernel 调试 → AscendC::PRINTF / DumpTensor / msDebug
症状-原因速查表
| 症状 | 可能原因 | 诊断方向 |
|---|---|---|
| 程序卡死/超时 | Buffer 未释放 / 死锁 | 检查 AllocTensor/FreeTensor 配对、EnQue/DeQue 配对 |
| 核心超时/挂起 | Buffer 冲突/死锁 | 检查 Alloc / Free 配对 |
| Segmentation Fault | 空指针解引用 / 内存越界 | GDB 分析 coredump → bt 查看调用栈 |
| Abort | 断言失败 / 异常终止 | GDB 分析 coredump → 检查断言条件 |
| 栈溢出 | 递归过深 / 大数组 | 检查 Kernel 内数组大小 |
| aic error | 内存访问越界 / 非对齐访问 | 检查 DataCopy 长度、32B 对齐 |
| AIV 卡死 | 跨核同步缺失 | 检查 CrossCoreWaitFlag 对应 SetFlag |
| drain 卡死 | 未发送 AIV→AIC flag | 检查 flag 发送链路 |
按场景进入详细流程
| 场景 | 说明 | 详细步骤 |
|---|---|---|
| 程序崩溃 | Segmentation Fault / Abort | Coredump 调试 |
| 程序卡死/超时 | Kernel 无响应、挂起 | Kernel 挂起调试 |
| Buffer 冲突/死锁 | Alloc/Free 不配对、同步缺失 | Buffer 问题排查 |
详细资源
- crash_workflow.md:完整调试流程 + 调试工具速查
- parse_plog.py:plog 日志解析脚本(自动识别卡死/崩溃/硬件异常信号)
- ascendc-env-check skill:环境变量配置指南
Current listing version
0.0.1
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 针对昇腾芯片开发中 Ascend C 算子卡死/崩溃这一高频刚需问题,提供系统化调试方案
- 覆盖程序崩溃、卡死、Buffer冲突、死锁等多种典型故障场景
Highlights
- 触发关键词覆盖全面且精准(卡死、挂起、超时、崩溃、hang、crash、deadlock、Segmentation Fault、Abort、Kernel hang、内存越界、plog)
Areas to improve
-
文档过长 Reported severity: Minor
SKILL.md 内容超过 500 行,影响阅读体验
Recommendation: 建议将部分内容移至引用文件中,保持主文档简洁
-
缺少 When to Use 章节 Reported severity: Minor
未明确说明何时使用此 Skill
Recommendation: 建议在文档开头增加 When to Use 章节,说明适用场景
-
排版问题 Reported severity: Minor
症状-原因速查表中 Segmentation Fault 拼写不一致(Fault vs fault)
Recommendation: 统一拼写格式为 Segmentation Fault
Highlights
- Phase/步骤清晰(快速诊断、症状-原因速查表、按场景进入详细流程),有出口条件和端到端示例
Areas to improve
-
重要可靠性问题 Reported severity: Major
parse_plog.py 脚本缺少具体使用说明和异常处理细节
Recommendation: 建议在 crash_workflow.md 中补充 parse_plog.py 的具体使用方法和异常处理说明
Highlights
- 工具来源明确(GDB、plog、AscendC::PRINTF等),参数正确,覆盖主要异常(coredump、Buffer配对、同步等)
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- gitcode.com
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.