Performance Code Size

Use Jeff Dean and Sanjay Ghemawat's canonical code-size guidance. Use when instruction-cache pressure, excessive inlining, template expansion, or repeated container operations may increase binary size or degrade performance.

boshjerns 39441d1 2 files · 1.1 KB Updated

File contents

Code size considerations

Read the exact current source section before applying it:

python3 ~/.codex/skills/performance-hints/scripts/fetch_section.py code-size-considerations --output text

Canonical section: Code size considerations

Attribute the guidance to Jeff Dean and Sanjay Ghemawat. Do not assume every hint applies: inspect the code, identify the relevant cost, and measure or estimate before recommending a change.

This section includes:

  • Trim commonly inlined code
  • Inline with care
  • Reduce template instantiations
  • Reduce container operations

boshjerns/performance-hints-agent-skills/tree/main/skills/performance-code-size commit 39441d1c3e

Frequently asked questions

npx skillmds@latest add boshjerns/performance-code-size