rocjitsu-project
Skill2 starsChanged 22 days agoApache-2.0View on GitHub
Work on, debug, review, or explain ROCm rocjitsu in rocm-systems/emulation/rocjitsu, including GPU simulation, DBT, DBI, KFD interposition, ISA semantics/codegen, plugins, and configuration.
In this repository12 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- cleanup-worktreesSkill
- find-security-vulnerabilitiesSkill
- gh-address-commentsSkill
- gh-fix-ciSkill
- peanut-reviewSkill
- pr-createSkill
- pr-reviewSkill
- rocjitsu-build-testSkill
- self-reviewSkill
- stage-and-commitSkill
- sync-reposSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 5 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 17
Only modify a canonical checkout when the user explicitly requests it.
- Very specific: line 23
Read CONTRIBUTING.md, docs/style.md, and the nearest applicable docs in the active checkout or task worktree before designing, adding, …
- Distinctive: line 32
Read references/technical-map.md when locating a subsystem, tracing cross-layer behavior, or assessing architectural impact.
- Very specific: line 34
When work depends on HSA runtime, libhsakmt, topology discovery, queue/event, or KFD-facing behavior, verify the contract against the …
- Very specific: line 50
Never edit generated ISA decoders, encoders, execute bodies, legalization tables, or encoding translators directly.
- Distinctive: line 59
Treat the daemon RPC transport as a trusted, local, version-matched transport, not a security boundary or network-facing protocol.
- Very specific: line 63
Follow the project's error model: Result/FailureOr<T> plus DiagnosticEmitter for expected failures.
- Very specific: line 67
Use util/log.h in libraries.
- Distinctive: line 78
Start with the smallest focused regression or characterization test that observes the contract at the affected layer.
- Distinctive: line 91
Keep simulated workloads deliberately small.
- Very specific: line 93
Use the rocjitsu-build-test skill after changes and choose verification in proportion to the affected layer.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 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
rocjitsu Project
Resolve the intended repository, development base, PR target, and worktree
root from the workspace's LOCAL_CONTEXT.md (if present) before selecting a
checkout. Its NPI routing applies to development, qualification, and PRs;
do not substitute the public base or the remote's default branch.
For public rocjitsu work, the canonical checkout is projects/rocm-systems,
with base develop; implementation work belongs in a branch-backed worktree
under projects/worktrees/rocm-systems/<task-slug>/. Internal work follows
the local routing and the workspace's projects-emu/ worktree convention.
Only modify a canonical checkout when the user explicitly requests it.
Paths below are relative to emulation/rocjitsu/ unless stated otherwise.
Establish context
- Read
CONTRIBUTING.md,docs/style.md, and the nearest applicable docs in the active checkout or task worktree before designing, adding, changing, or reviewing code. Followdocs/style.mdfor implementation and assess changed code against it during reviews. These project rules override generic workspace C++ guidance. - Inspect the current branch, diff, and local changes. Preserve unrelated work.
- Identify the affected execution strategy: simulation, dynamic binary translation (DBT), or dynamic binary instrumentation (DBI). Do not assume a behavior or test from one path covers another.
- Read references/technical-map.md when locating a subsystem, tracing cross-layer behavior, or assessing architectural impact.
- When work depends on HSA runtime, libhsakmt, topology discovery, queue/event,
or KFD-facing behavior, verify the contract against the checked-out ROCR
source at
<rocm-systems>/projects/rocr-runtime/. Treat it as source context, not a rocjitsu build dependency or an ordinary edit target. - For debugger integration, GPU breakpoints, stepping, wave/register inspection,
or debugger launch/resume issues, consult
<workspace>/projects/rocgdb/. See the rocGDB source map for entry points and the debugger worktree convention.
Engineering invariants
- rocjitsu is a C++20 project inside the
ROCm/rocm-systemsmonorepo. It runs unmodified HIP/ROCR applications by interposing at the KFD/DRM boundary, or rewrites already-compiled AMDGPU code objects through DBT/DBI. - Extend
lib/util,lib/simdojo, and existing rocjitsu components before adding libraries, dependencies, abstractions, or duplicate helpers. - Never edit generated ISA decoders, encoders, execute bodies, legalization
tables, or encoding translators directly. Change the
amdisagenerator, regenerate withscripts/generate-amdisa.sh, and keep generator and generated output in the same change. - Preserve ISA identity distinctions. Architecture families, concrete
gfxtargets, ELF/code-object identities, and configured simulated devices are related but not interchangeable. - Translation must fail closed for unsupported or ambiguous instructions. Preserve diagnostics and avoid silently emitting guessed semantics.
- Treat the daemon RPC transport as a trusted, local, version-matched transport, not a security boundary or network-facing protocol.
- Simulation hot paths are sensitive to allocations, exceptions, logging, and synchronization. Use project utilities and measure performance changes.
- Follow the project's error model:
Result/FailureOr<T>plusDiagnosticEmitterfor expected failures; exceptions only for unrecoverable initialization, configuration, or execution failures. Catch only at a boundary that translates the failure. - Use
util/log.hin libraries. Trace groups may compile out; useLogger::warn()for always-visible warnings. Respect the documented CLI and ROCR-hookstderrcarve-outs. - For config changes, update the FlatBuffers schema, parsing/validation, topology construction, representative configs, and tests together.
- Large public API, subsystem, translation-pair, KFD/RPC, or dependency changes
require the design-proposal process in
CONTRIBUTING.md; localized fixes and tests do not.
Change strategy
- Start with the smallest focused regression or characterization test that observes the contract at the affected layer.
- Mirror source structure under
tests/(dbt/,patch/,analysis/,race-detector/, and so on). - For instruction semantics, prefer decode/execute harness tests and exact scalar/SIMD correctness checks. Include edge operands, masks, modifiers, widths, and architecture gates relevant to the encoding.
- For DBT/DBI, verify both transformed structure and executable behavior when practical. Check branches, relocations, symbols, descriptors, scratch/LDS, register liveness, and unsupported-case diagnostics.
- For KFD, daemon, queue, or memory changes, test lifecycle, cleanup, error paths, concurrency, and both local and daemon mode when the contract spans them.
- Keep simulated workloads deliberately small. CPU simulation can be orders of magnitude slower than hardware.
- Use the
rocjitsu-build-testskill after changes and choose verification in proportion to the affected layer.
Primary project references
README.md: supported architectures, feature maturity, entry pointsCONTRIBUTING.md: contribution rules, code placement, style, error handlingdocs/style.md: required coding style for new and changed code and code reviewsdocs/architecture.md: layer and component mapdocs/vm-design.md,docs/simdojo.md: simulation and schedulingdocs/dbt-design.md,docs/dbi-design.md: binary transformationdocs/codegen.md,docs/isa-target-providers.md: ISA generation/registrationdocs/configuration.md,docs/plugins.md,docs/rocjitsu-cli.md: user/runtime contractsdocs/benchmarking.md: performance and memory measurement protocol
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.

