gpu-memory-model

gpu-memory-model is a skill for Claude Code, Codex from mohitmishra786/low-level-dev-skills. It costs 70 tokens per session (1,965 once invoked), scanned A, original, MIT.

A guide to how GPUs execute many threads together and move data through registers, shared memory, caches, and device memory.

In plain words
What is it for?
Use it to analyze memory-bound GPU kernels, choose block sizes, understand occupancy, compare NVIDIA warps with AMD wavefronts, and reason about atomic operations.
Why use it?
It explains performance problems such as branch divergence, poorly arranged memory access, shared-memory conflicts, and excessive resource use.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to analyze memory-bound GPU kernels, choose block sizes, understand occupancy, compare NVIDIA warps with AMD wavefronts, and reason about atomic operations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mohitmishra786/low-level-dev-skills/gpu-memory-model
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add mohitmishra786/low-level-dev-skills --skill gpu-memory-model
Clone the repo
git clone --depth 1 https://github.com/mohitmishra786/low-level-dev-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for gpu-memory-model

README.md
[![agentmods](https://agentmods.dev/badge/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model/github.svg)](https://agentmods.dev/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model)
Your own site
<a href="https://agentmods.dev/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model"><img src="https://agentmods.dev/badge/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for gpu-memory-model

Your own site · 80×15
<a href="https://agentmods.dev/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model"><img src="https://agentmods.dev/badge/skills/mohitmishra786/low-level-dev-skills/gpu-memory-model.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,965 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00070 $0.01965
Opus 5 $0.00035 $0.00983
Sonnet 5 $0.00014 $0.00393
Haiku 4.5 $0.00007 $0.00197

Measured 6d ago against content hash 98535a7946b9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

gpu-memory-model scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/gpu/gpu-memory-model/SKILL.md · 217 lines

How it starts

The opening of the file, as written. The whole thing — 217 lines — stays where its author put it; the contents beside it link to each section on GitHub.

GPU Memory Model

Purpose

Explain the GPU execution and memory model for agents optimizing kernels: SIMT execution, warp (32) vs wavefront (64) divergence costs, global memory coalescing rules, shared memory bank conflicts, L1/L2 cache behavior, atomic memory ordering, and the occupancy-vs-latency-hiding tradeoff.

When to Use

  • Diagnosing why a kernel is memory-bound despite high theoretical bandwidth
  • Understanding warp divergence from branching
  • Fixing shared memory bank conflicts in tiled algorithms
  • Choosing block size for occupancy vs register pressure
  • Porting kernels between NVIDIA (warp 32) and AMD (wavefront 64)
  • Reasoning about atomic contention in parallel reductions

Workflow

1. SIMT execution model

GPU hardware
├── Device
│   └── SM / CU (Streaming Multiprocessor / Compute Unit)
│       ├── Warp schedulers (NVIDIA) or Wavefront schedulers (AMD)
│       │   └── Warp/Wavefront (32 or 64 threads in lockstep)
│       ├── Register file (partitioned per thread)
│       ├── Shared memory / LDS (per SM)
│       └── L1 cache (often shared with shared memory)
└── L2 cache (device-wide) → DRAM/HBM

SIMT (Single Instruction, Multiple Threads): one instruction stream drives a warp/wavefront; each thread has its own registers and thread ID but executes the same instruction in lockstep.

2. Warp vs wavefront

Vendor Unit size Name
NVIDIA 32 threads Warp
AMD 64 threads Wavefront

Implications:

  • Reduction trees: NVIDIA halves at 16→8→4→2→1; AMD at 32→16→8→4→2→1
  • Block sizes: prefer multiples of 32 (NVIDIA) or 64 (AMD)
  • Occupancy counters report active warps/wavefronts per SM

3. Warp divergence cost model

When threads in a warp take different branches, the hardware serializes paths:

// Divergent: half warp does A, half does B → 2x instruction issue
if (threadIdx.x % 2 == 0) {
    result = expensive_a(data[idx]);
} else {
    result = expensive_b(data[idx]);
}

// Non-divergent: all threads same path
result = expensive_a(data[idx]);

Read the full file on GitHub · 217 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 217 lines · 70 tokens per session scan A 98535a7946b9

Subscribe to this mod's changes

gpu-memory-model is a skill published in the GitHub repository mohitmishra786/low-level-dev-skills (198 stars, last pushed 2mo ago), licensed MIT. It adds 70 tokens to every session and 1,965 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

fusion-360

Comprehensive operational skill specification for Anthropic Claude to automate, script, troubleshoot, and optimize Autodesk Fusion (Fusion 360), Python API (adsk.fusion), Parametric Timeline, and CAM toolpaths.

alivirgo/Major-AI-Skills · 46 tokens

altium-designer

Comprehensive operational skill specification for Anthropic Claude to automate, script, troubleshoot, and optimize Altium Designer, DXP scripting engine, DRC rules, OutJob CAM generation, and high-speed PCB routing.

alivirgo/Major-AI-Skills · 47 tokens

eartrumpet

Comprehensive operational skill specification for Anthropic Claude to automate, script, troubleshoot, and optimize EarTrumpet, Windows Core Audio APIs (WASAPI), pycaw audio session automation, and per-app endpoint routing.

alivirgo/Major-AI-Skills · 49 tokens

codesys

Comprehensive operational skill specification for Anthropic Claude to automate, script, troubleshoot, and optimize CODESYS V3.5, IEC 61131-3 Structured Text (ST), ScriptEngine Python automation, EtherCAT/PROFINET, and OPC UA.

alivirgo/Major-AI-Skills · 56 tokens

pcbway

PCBWay PCB fabrication and assembly — turnkey/consigned assembly, design rules, ordering workflow. Alternative to JLCPCB for manufacturing. Use with KiCad. Use this skill when the user mentions PCBWay, needs turnkey assembly (PCBWay sources parts by MPN), has parts not available on LCSC, needs assembled boards with…

aklofas/kicad-happy · 119 tokens

unifi-protect

How to manage UniFi Protect cameras and NVR — view cameras, smart detections, Find Anything detection search, recordings, snapshots, lights, sensors, Known Faces, license plates, and the Alarm Manager. Use this skill when the user mentions UniFi cameras, security cameras, NVR, recordings, motion detection, person…

sirkirby/unifi-mcp · 112 tokens