openxiangshan/xiangshanlab/xiangshan-mpt-dut
Claude Code and agent skill by openxiangshan/xiangshanlab
- community
Checking that the SKILL.md file is still in the repository.
Generate or update a compact Chisel/Scala DUT that isolates XiangShan MPT checking logic from the full core. Use when working on XiangShan MPT, MptChecker.scala, L2TLB MPT wiring, backend/decode mfence support, or the custom smmpt/mmpt CSR path, especially when asked to regenerate a simple DUT around MPT upstream/downstream logic for simulation or verification.
Install
npx vskill@latest install openxiangshan/xiangshanlab/xiangshan-mpt-dutSKILL.md
XiangShan MPT DUT
Workflow
Use this skill to rebuild a small DUT around XiangShan's MPT checker without dragging in the whole core.
- Inspect the local XiangShan source before editing. Prefer
rgand targetedsedreads. - Load references/mpt-dut-generation.md before implementing the DUT.
- Keep the DUT focused on
MptCheckerand its real upstream/downstream contract:
- upstream request/response:
MptReqBundleandMptRespBundle - CSR input:
TlbCsrBundle.mmpt - flush input:
SfenceBundle, includingmfencewhenHasMptCheck - memory side:
L2TlbMemReqBundlerequest plus XLEN response - PMP side:
PMPReqBundleandPMPRespBundle
- Preserve the XiangShan parameter gate: the DUT should be meaningful only with
HasMptCheck = true. - Do not model the full backend, ROB, LSQ, PTW cluster, or complete L2TLB unless the user explicitly asks. Replace them with small drivers, arbiters, memories, or stubs that preserve handshake semantics.
Output Shape
Prefer one of these forms, matching the repository style:
- A new Chisel module such as
SimpleMptDUT,MptCheckerDUT, or a project-specific name requested by the user. - A minimal test/harness module that instantiates
MptChecker, drives CSR/mfence/PMP/memory, and exposes decoupled request/response IO. - A generator target only if the repository already has a clear pattern for standalone generators.
Keep source changes narrow. Avoid unrelated CSR, decode, or L2TLB refactors.
Validation
After generating the DUT:
- Run the narrowest available Scala/Chisel compile or generator command for the touched module.
- If no compile target exists, run a syntax-oriented check available in the repo and state the limitation.
- Recheck all
Option.when(HasMptCheck)fields so the DUT does not dereference optionalmfenceor MPT fields when disabled.
Security
- Security scanPassed, 90 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 repositoryCheckingxiangshan-programming-practice/mmu-smmpt/skill/xiangshan-mpt-dut/SKILL.md
Popularity
- 7-day trend score
- 0
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/openxiangshan/xiangshanlab/xiangshan-mpt-dut)