mohitmishra786/low-level-dev-skills/cpu-pipelines-and-hazards
Claude Code and agent skill by mohitmishra786/low-level-dev-skills
- community
Checking that the SKILL.md file is still in the repository.
CPU pipeline skill for hazards, forwarding, and stalls. Use when explaining pipeline stages, data/control hazards, forwarding paths, or branch stalls in performance analysis. Activates on queries about pipeline hazard, data hazard, control hazard, forwarding, pipeline stall, or superscalar basics.
Install
npx vskill@latest install mohitmishra786/low-level-dev-skills/cpu-pipelines-and-hazardsSKILL.md
CPU Pipelines and Hazards
Purpose
Explain classic and modern CPU pipeline concepts: stages, data and control hazards, forwarding/bypassing, stalls, and branch handling — foundational for optimization and understanding microarchitecture counters.
When to Use
- Interpreting pipeline stall metrics from
skills/profilers/intel-vtune-amd-uprof - Teaching why instruction order affects throughput
- Relating assembly scheduling to hardware behavior
- Debugging unexpected performance cliffs in hot loops
Workflow
1. Five-stage classic pipeline (MIPS-style mental model)
Overlapped execution: instruction N in EX while N+1 in ID.
2. Data hazards
| Type | Example | Mitigation | |
|---|---|---|---|
| RAW (true) | add r1,r2,r3 then sub r4,r1,r5 | Forwarding from EX/MEM/WB | |
| WAR / WAW | Rare in in-order; relevant in OoO rename | Register renaming |
Without forwarding:
3. Control hazards (branches)
See skills/computer-architecture/branch-prediction-and-speculation.
4. Structural hazards
Limited functional units (single memory port) cause stalls even without dependencies.
5. Practical optimization hints
Pair with skills/low-level-programming/cpu-cache-opt — memory often dominates.
6. Reading uops / ports (x86)
VTune "Microarchitecture Exploration" maps to pipeline slots.
7. Agent usage
Common Problems
| Symptom | Cause | Fix | |
|---|---|---|---|
High stalls-frontend | I-cache misses / branch mispredict | Align hot loop; see branch skill | |
| No speedup from unroll | Memory bound | Profile loads; prefetch | |
| Wrong cycle model | Ignored OoO execution | Use perf hardware counters | |
| "NOP fixes it" | Timing-sensitive MMIO | Never tune device delays by NOP |
Related Skills
skills/computer-architecture/branch-prediction-and-speculation— mispredict costskills/computer-architecture/memory-hierarchy-and-caches— load latencyskills/low-level-programming/cpu-cache-opt— cache-line effectsskills/profilers/intel-vtune-amd-uprof— pipeline analysisskills/low-level-programming/assembly-arm— instruction scheduling
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/computer-architecture/cpu-pipelines-and-hazards/SKILL.md
Popularity
- Repository stars
- 237
- Repository forks
- 28
- 7-day trend score
- 27
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/mohitmishra786/low-level-dev-skills/cpu-pipelines-and-hazards)