concurrency-verifier
Skill17 starsChanged 9 months agoApache-2.0View on GitHub
Verify concurrent and parallel programs for data races, deadlocks, and correctness.
In this repository98 other files it gives its agents.
- abstract-interpretation-engineSkill
- abstract-machineSkill
- acsl-annotation-assistantSkill
- actor-model-implementerSkill
- algebraic-effectsSkill
- alias-and-points-to-analysisSkill
- axiomatic-semanticsSkill
- bidirectional-type-checkingSkill
- bisimulation-checkerSkill
- capability-systemSkill
- closure-converterSkill
- common-subexpression-eliminatorSkill
- constant-propagation-passSkill
- contextual-equivalenceSkill
- control-flow-analysisSkill
- coq-proof-assistantSkill
- cps-transformerSkill
- dafny-verifierSkill
- dataflow-analysis-frameworkSkill
- dead-code-eliminatorSkill
- defunctionalizationSkill
- denotational-semantics-builderSkill
- dependent-type-implementerSkill
- dsl-embeddingSkill
- effect-handlers-implementerSkill
- effect-systemSkill
- effect-type-systemSkill
- escape-analysisSkill
- existential-typesSkill
- ffi-designerSkill
- fuzzer-generatorSkill
- gadt-implementerSkill
- garbage-collector-implementerSkill
- graalvm-truffle-implementerSkill
- gradual-typing-implementerSkill
- higher-order-abstract-syntaxSkill
- hoare-logic-verifierSkill
- incremental-computationSkill
- information-flow-analyzerSkill
- inline-expanderSkill
- interprocedural-analysisSkill
- invariant-generatorSkill
- jit-compiler-builderSkill
- lambda-calculus-interpreterSkill
- language-server-protocolSkill
- lean-proverSkill
- lexer-generatorSkill
- linear-type-implementerSkill
- liveness-analysisSkill
- llvm-backend-generatorSkill
- lock-free-data-structureSkill
- loop-optimizerSkill
- loop-termination-proverSkill
- macro-expanderSkill
- memory-allocatorSkill
- message-passing-systemSkill
- mlir-dialect-designerSkill
- model-checkerSkill
- module-systemSkill
- monad-transformerSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 7 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈7
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 26
Deadlock Analysis: Check for potential deadlocks
- Distinctive: line 27
Lock Verification: Verify lock usage patterns
- Distinctive: line 29
Liveness Checking: Ensure progress properties
- Distinctive: line 43
Use consistent lock ordering to prevent deadlocks
- Distinctive: line 44
Prefer message passing over shared memory
- Distinctive: line 45
Use ownership types when possible (Rust)
- Distinctive: line 46
Test with thread sanitizers
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Concurrency Verifier
Concurrency verification ensures that parallel programs are free from data races, deadlocks, and other concurrency bugs. It is essential for reliable multi-threaded and distributed systems.
When to Use This Skill
- Verifying multi-threaded programs
- Detecting data races
- Proving deadlock freedom
- Verifying lock protocols
- Building reliable concurrent systems
What This Skill Does
- Race Detection: Identify unsynchronized shared access
- Deadlock Analysis: Check for potential deadlocks
- Lock Verification: Verify lock usage patterns
- Memory Model Reasoning: Reason about weak memory models
- Liveness Checking: Ensure progress properties
Key Concepts
| Concept | Description |
| Data Race | Unsynchronized concurrent access to shared data |
| Deadlock | Circular waiting on locks |
| Lock Order | Protocol for acquiring locks to prevent deadlock |
| Ownership | Exclusive access right to data |
| Memory Model | Rules for visibility of writes across threads |
Tips
- Use consistent lock ordering to prevent deadlocks
- Prefer message passing over shared memory
- Use ownership types when possible (Rust)
- Test with thread sanitizers
- Model check critical sections
Common Use Cases
- Multi-threaded server verification
- Lock-free data structure verification
- Distributed system verification
- Operating system kernels
- Database concurrency control
Related Skills
separation-logician- Foundation for concurrent separation logicmodel-checker- Exhaustive concurrent state explorationrust-borrow-checker- Rust's ownership systemweak-memory-model-verifier- For relaxed memory models
Canonical References
| Reference | Why It Matters |
| O'Hearn, "Resources, Concurrency and Local Reasoning" (TCS 2007) | Concurrent separation logic |
| Herlihy & Shavit, "The Art of Multiprocessor Programming" | Concurrent algorithms |
| Herlihy & Wing, "Linearizability: A Correctness Condition for Concurrent Objects" (TOPLAS 1990) | Correctness criterion |
Tradeoffs and Limitations
Approach Tradeoffs
| Approach | Pros | Cons |
| Static analysis | Fast | May miss races |
| Model checking | Complete | State explosion |
| Type-based | Compile-time | Conservative |
When NOT to Use This Skill
- Single-threaded programs
- When testing suffices
- Performance-critical lock-free code (use specialized verification)
Limitations
- Weak memory models are hard
- Dynamically created threads
- Library callbacks
Assessment Criteria
A high-quality implementation should have:
| Criterion | What to Look For |
| Soundness | Catches all races |
| Precision | Few false positives |
| Scalability | Handles realistic programs |
| Usability | Clear error reporting |
Quality Indicators
✅ Good: Catches real races, handles common patterns ⚠️ Warning: Many false positives ❌ Bad: Misses real races
Research Tools & Artifacts
Real-world concurrency verification tools:
| Tool | Why It Matters |
| ThreadSanitizer | Dynamic race detection in LLVM/GCC |
| CHESS | Microsoft's deterministic concurrency testing |
| CalFuzzer | Dynamic race detection for Java |
| SPIN | Model checker for concurrent systems |
| Verifast | Concurrent separation logic |
| Iris | Higher-order concurrent separation logic |
Key Verification Systems
- Rocket (Amazon): Static verification of DynamoDB
- SeL4: Verified microkernel with concurrent reasoning
- RCC (Rust): Concurrent verifier for Rust
Research Frontiers
Current concurrency verification research:
| Direction | Key Papers | Challenge |
| Weak memory | Alglave et al. "Weak Memory Models" | x86/ARM/POWER models |
| Lock-free | Various verification approaches | CAS and queues |
| Linearizability | Herlihy & Wing (TOPLAS 1990) | Atomic object verification |
| Fencing | "Fence Inference" (2015) | Minimal memory fences |
| Regression | "Concurrency Bug Detection" (2019) | Finding regression bugs |
Hot Topics
- AI for concurrency: Learning bug patterns
- Quantum concurrency: Verification of quantum protocols
- Distributed systems: Cross-node verification
Implementation Pitfalls
Common concurrency verification bugs:
| Pitfall | Real Example | Prevention |
| Missing volatile | TSan missed race | Track atomics precisely |
| Lock ordering violations | Deadlock not detected | Check lock graph |
| Signal handlers | Unsafe signal usage | Model async signals |
| Atomics vs locks | Confusion about semantics | Separate verification |
| Condition variables | Spurious wakeups | Model precisely |
| Memory fences | Weaker than needed | Check fence model |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

