Rust 并发安全
SkillCommunicationLets your agent apply the rust claude skill to design and debug locks, atomics, and async code in TGOSKits.
Use Rust 并发安全 in Claude, ChatGPT or Ahel Desktop
Free. Sign in, add Rust 并发安全 and connect your AI. About a minute.
Also: Claude Code · Cursor · Codex
Then ask your AI: use the Rust 并发安全 skill
Details
Instructions available. Your AI can read the instructions. Execution depends on the setup they require.
Account requirements not reviewed. Check the skill instructions before use; ahel provides instructions and does not run this skill.
No other account needed.
Add ahel to your AI once: Claude, ChatGPT, Cursor, Claude Code or Codex. Then ask it to use this.
About this skill
Use when designing, modifying, debugging, or reviewing locks, atomic operations, task scheduling, async execution, interrupt contexts, cross-core notifications, shared state, or resource lifecycles in TGOSKits. Read-only data structures or explicitly single-threaded code do not trigger this skill.
What this skill tells your AI
The instructions your AI receives, as published by rcore-os/tgoskits in .agents/skills/rust-concurrency-safety/SKILL.md and read by ahel’s review.
1. 适用方式
只要正确性依赖两个以上执行上下文之间的顺序、可见性或资源生命周期,就使用本技能。执行上下文包括任务、线程、处理器、中断、软中断、异步任务、设备和客户机虚拟处理器。
锁、临界区、回调和生命周期问题完整阅读 锁与生命周期。原子操作、内存顺序、无锁状态、异步执行或取消问题完整阅读 原子操作与异步执行。同一改动可以同时读取两份资料。
2. 分析顺序
先列出共享对象、所有者、所有读写执行上下文和允许的状态转换,再确定同步原语。优先级依次是不共享、通过消息转移所有权、共享不可变 Arc、使用保护明确不变量的锁、使用能够独立证明的原子状态,最后才是需要手工健全性证明的非安全共享。不要从“换一把更快的锁”或“把内存顺序调强”开始;必须说明发布者、观察者、保护对象、等待条件和释放路径。
公共类型跨执行上下文移动或共享时,检查其全部字段和生命周期是否正确满足 Send 或 Sync;不能因为外层包了 Arc 就假定内部状态可并发访问。涉及 unsafe impl Send、unsafe impl Sync、裸指针、直接内存访问或设备共享内存时,同时使用 rust-unsafe-safety。任务调度和跨核通知仍需结合实际子系统与平台技能判断。
3. 验收条件
实现和审查结果必须能够回答:每个状态由谁写入、由谁观察、依靠哪条同步边建立先后关系、等待如何被唤醒、取消或失败如何释放资源、是否存在丢失唤醒、重复完成、死锁、陈旧标识符或释放后访问。测试应确定性覆盖关键交错,而不是依赖长时间压力运行碰巧触发。
Signals
- GitHub stars
- 74
- Forks
- 137
- Last commit
- Oct 2026
Advanced
- Item type
- skill
- Key
rust-concurrency-safety- Source
- github.com/rcore-os/tgoskits
More in Communication
Skill · anthropics
More in Communicationerror-handling
Skill · affaan-m
More in Communicationwait-what
Skill · mattpocock
More in Communicationemails
Skill · coreyhaines31
More in Communicationazure-messaging
Skill · microsoft
More in Communicationinvestor-outreach
Skill · affaan-m
More in Communication