What problem does it solve? When a model running on MAX feels slow, you need to know whether the GPU is actually saturated, which kernels consume the most time, and why a specific kernel underperforms. This Skill provides a cheapest-first diagnostic workflow that answers those three questions without capturing more profiling data than necessary. ## Core Features & Use Cases - GPU Utilization Check: Sample compute usage, memory, and throttle reasons on NVIDIA and AMD GPUs using the pure-Python max.profiler.gpu API and the bundled gpu_snapshot.py script. - Kernel Breakdown: Capture ranked top-N GPU kernel tables via max generate --profile, Nsight Systems on NVIDIA, or rocprofv3 on AMD, with NVTX phase markers for prefill, decode, and sampling. - Single-Kernel Deep Dive: Use Nsight Compute (ncu) to analyze occupancy, stalls, and roofline position for one dominant kernel. - Custom Architecture Support: Profile models loaded with --custom-architectures, including import-drift checks, PYTHONPATH traps, and chat-template workarounds. - Use Case: A user serving Llama-3.1-8B notices low tokens per second. The Skill first confirms the GPU is busy, then captures a kernel breakdown showing gemv_split_k GEMVs dominating decode — the healthy expected shape — ruling out a kernel problem and pointing at batch configuration instead. ## Quick Start Ask the assistant to profile your model on MAX, for example: "Profile my model running with max serve and tell me where it spends GPU time."