Use when explaining System V AMD64, ARM AAPCS, RISC-V psABI, stack frames, variadic calls, or FFI register rules. Not for the Rust FFI binding layer: use rust-ffi.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when explaining branch predictors, mispredict penalties, speculative execution, Spectre or Meltdown mitigations, or branchless code. Not for pipeline stage theory: use cpu-pipelines-and-hazards.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
설치 방법 보기설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.
| Field | Bound contract |
|---|---|
| Trigger | Branchy hot code underperforms, a likely or branchless refactor needs judgment, a kernel mitigation such as retpoline or KPTI needs explaining, or code branches on secret data. |
| Authority | Read-only. The skill runs perf stat on a user-named binary, reads sysfs, and answers in chat. Nothing on disk changes, so there is nothing to roll back. No remote mutation. |
| Side effect | Chat output only. perf stat writes counters to stdout. |
| Done | The answer names the branch that mispredicts or the speculation path that leaks, gives a measured branch-misses count where a binary exists, and states the fix with the condition under which it helps. |
branch-misses count and its ratio to branches for the real workload is recorded, or no binary exists and the answer is marked as unmeasured.perf stat -e branches,branch-misses ./app
Read the ratio against the workload, not against a fixed number: a tight loop over sorted data should show a ratio near zero, while a parser over random input can sit far higher and still be at its floor. Only a ratio that drops after a change proves the change.
int m = a < b ? a : b; may lower to cmov. The select executes both operands every time, so it wins only when the branch mispredicts often; on a predictable branch it loses.__builtin_expect(!!(x), 1) and __builtin_expect(!!(x), 0) steer code layout, not the dynamic predictor. On a current out-of-order core the predictor already learns most static patterns, so the hint helps layout of the cold path and little else. Measure after adding one. Done when: the hint is kept only with a measured win./sys/devices/system/cpu/vulnerabilities/ (one file per issue, such as spectre_v1, spectre_v2, meltdown, l1tf). Retpoline, IBRS, IBPB, and STIBP appear in the spectre_v2 text. A host booted with mitigations=off reports Vulnerable here.-mspeculative-load-hardening masks pointers on the speculative path.For the pipeline model behind the penalty, use cpu-pipelines-and-hazards. For cache timing channels, use cpu-cache-opt. For the kernel mitigation set (KPTI, CET), use kernel-security.
| Failure class | Behavior |
|---|---|
| No binary or workload | Deliver the mechanism and the candidate fixes as hypotheses. Mark the answer unmeasured. |
perf stat denied | Report the perf_event_paranoid value the tool prints and the capability it needs. Do not change the sysctl. |
| Hint shows no gain | The predictor already handled the branch. Remove the hint and profile for the real bottleneck. |
| Branchless version slower | The branch was predictable and the select now executes both operands. Revert and benchmark on the target CPU. |
| Mitigation regresses throughput | Name the mitigation and its cost. Isolating the secret-handling code is the alternative; do not recommend disabling mitigations. |
A chat answer that names the mechanism, the measured branch-misses figure when a binary exists, one chosen remedy with its winning condition, and the mitigation layer that applies when secrets are involved.
아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.
로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.
아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.
Use when explaining System V AMD64, ARM AAPCS, RISC-V psABI, stack frames, variadic calls, or FFI register rules. Not for the Rust FFI binding layer: use rust-ffi.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when configuring ADC sampling time, DMA-driven ADC, calibration, or DAC channel setup on bare-metal MCUs. Not for the DMA stream itself: use dma-baremetal.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when creating AF_XDP sockets, configuring UMEM and XSK rings, writing an XDP redirect program, or choosing copy versus zero-copy mode. Not for full kernel bypass: use dpdk.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when a completed session needs an agent-environment retrospective. Not for an engineering retrospective from telemetry: use engineering-retrospective.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when a redacted, trimmed agent transcript must be appended to a GitHub PR or issue body, with human approval and preview. Not for automated or model-initiated insertion.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Use when a repo needs agent setup, AGENTS.md added or made lean, CLAUDE.md audited, or agent instructions scored or pruned. Not for remote, credential, publish, deploy, or irreversible changes.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.