en un clic
axiom-performance
// Use when app feels slow, memory grows, battery drains, or diagnosing ANY performance issue. Covers memory leaks, profiling, Instruments workflows, retain cycles, performance optimization.
// Use when app feels slow, memory grows, battery drains, or diagnosing ANY performance issue. Covers memory leaks, profiling, Instruments workflows, retain cycles, performance optimization.
Use when the user mentions GRDB performance review, slow GRDB queries, app-group database setup audit, or pre-release GRDB scan.
Use when writing ANY async code, actors, threads, or seeing ANY concurrency error. Covers Swift 6 concurrency, @MainActor, Sendable, data races, async/await patterns.
Use when working with ANY data persistence, database, storage, CloudKit, migration, or serialization. Covers SwiftData, Core Data, GRDB, SQLite, CloudKit sync, file storage, Codable, migrations.
Use when integrating ANY iOS system feature - Siri, Shortcuts, widgets, IAP, localization, privacy, alarms, calendar, reminders, contacts, background tasks, push notifications, timers. Covers App Intents, WidgetKit, StoreKit, EventKit, Contacts.
Use when storing credentials securely, encrypting data, implementing passkeys, code signing, or managing certificates and provisioning profiles.
Use when building, fixing, or improving ANY SwiftUI UI — views, navigation, layout, animations, performance, architecture, gestures, debugging, iOS 26 features.
| name | axiom-performance |
| description | Use when app feels slow, memory grows, battery drains, or diagnosing ANY performance issue. Covers memory leaks, profiling, Instruments workflows, retain cycles, performance optimization. |
| license | MIT |
You MUST use this skill for ANY performance issue including memory leaks, slow execution, battery drain, or profiling.
Use this router when:
Memory leaks (Swift) → See skills/memory-debugging.md
Memory leak scan → Launch memory-auditor agent or /axiom:audit memory (5-phase semantic audit: maps resource ownership, detects 6 leak patterns, reasons about missing cleanup, correlates compound risks, scores lifecycle health)
Memory leaks (Objective-C blocks) → See skills/objc-block-retain-cycles.md
Performance profiling (GUI) → See skills/performance-profiling.md
Automated profiling (CLI) → See skills/xctrace-ref.md
Run automated profile → Use performance-profiler agent or /axiom:profile
App hangs or freezes → See skills/hang-diagnostics.md
Slow app launch → See skills/app-launch.md
dyld Activity, measurement hygiene+load, mergeable libraries), main-thread deferral, priority inversionXCTApplicationLaunchMetric regression test, MXAppLaunchMetric field histograms, custom "app is interactive" signpostBattery drain, high energy → See skills/energy.md
Symptom-based diagnosis → See skills/energy-diag.md
API reference with code → See skills/energy-ref.md
Energy scan → Launch energy-auditor agent or /axiom:audit energy (8 anti-patterns: timer abuse, polling, continuous location, animation leaks, background mode misuse, network inefficiency, GPU waste, disk I/O)
Timer crash patterns (DispatchSourceTimer) → See axiom-integration (skills/timer-patterns.md)
Timer API reference → See axiom-integration (skills/timer-patterns-ref.md)
Swift performance optimization → See skills/swift-performance.md
Swift performance scan → Launch swift-performance-analyzer agent or /axiom:audit swift-performance (unnecessary copies, ARC overhead, unspecialized generics, collection inefficiencies, actor isolation costs, memory layout)
Modern Swift idioms → See axiom-swift (skills/swift-modern.md)
MetricKit API reference → See skills/metrickit-ref.md
Capture simulator console output → /axiom:console
--timeout and --max-linesLLDB interactive debugging → See axiom-build (skills/lldb.md)
LLDB command reference → See axiom-build (skills/lldb-ref.md)
axiom-concurrency (callback contention, not profiling)/axiom:console.ips, MetricKit, or legacy .crash text file to symbolicate/triage? → axiom-tools (skills/xcsym-ref.md) or /axiom:analyze-crash| Thought | Reality |
|---|---|
| "I know it's a memory leak, let me find it" | Memory leaks have 6 patterns. memory-debugging diagnoses the right one in 15 min vs 2 hours. |
| "I'll just run Time Profiler" | Wrong Instruments template wastes time. performance-profiling selects the right tool first. |
| "Battery drain is probably the network layer" | Energy issues span 8 subsystems. energy skill diagnoses the actual cause. |
| "App feels slow, I'll optimize later" | Performance issues compound. Profiling now saves exponentially more time later. |
| "It's just a UI freeze, probably a slow API call" | Freezes have busy vs blocked causes. hang-diagnostics has a decision tree for both. |
| "Memory is climbing AND scrolling stutters — two separate bugs" | Memory pressure causes GC pauses that drop frames. Fix the leak first, then re-check scroll performance. |
| "It only freezes on first launch, must be loading something" | First-launch hangs have 3 patterns: synchronous I/O, lazy initialization, main thread contention. hang-diagnostics diagnoses which. |
| "Launch feels slow — I'll trim some startup code" | Launch has 3 phases (pre-main / main→first frame / extended) and a watchdog. app-launch tells you which phase to profile, with measurement hygiene so the number means something. |
| "Launch is fine, it's fast on my phone" | Measure on your oldest supported device with a Release build. app-launch has the full hygiene checklist — newest-device numbers hide the regression. |
| "Resume from the app switcher is slow too" | Resume isn't a launch — never measure it as one. app-launch distinguishes cold/warm/hot/notification and how to reproduce each. |
| "UI locks up when network requests finish — that's slow" | Multiple callbacks completing at once = main thread contention = concurrency issue. Cross-route to axiom-concurrency. |
| "I'll just add print statements to debug this" | Print-debug cycles cost 3-5 min each (build + run + reproduce). An LLDB breakpoint costs 30 seconds. axiom-build (skills/lldb.md) has the commands. |
| "I can't see what the app is logging" | xclog captures print() + os_log from the simulator with structured JSON. /axiom:console. |
| "I'll hand-parse this .ips JSON to see the top frame" | xcsym parses, discovers dSYMs, symbolicates, and categorizes in one call — structured JSON with pattern_tag. /axiom:analyze-crash. |
| "I'll just use Timer.scheduledTimer, it's simpler" | Timer stops during scrolling (.default mode), retains its target (leak). timer-patterns has the decision tree. |
| "DispatchSourceTimer crashed but it's intermittent, let's ship" | DispatchSourceTimer has 4 crash patterns that are ALL deterministic. timer-patterns diagnoses which one. |
| "Claude already knows modern Swift" | Claude defaults to pre-5.5 patterns (Date(), CGFloat, filter().count). swift-modern has the correction table. |
Memory Debugging (memory-debugging):
Performance Profiling (performance-profiling):
Energy Optimization (energy):
User: "My app's memory usage keeps growing" → See skills/memory-debugging.md
User: "I have a memory leak but deinit isn't being called" → See skills/memory-debugging.md
User: "My app feels slow, where do I start?" → See skills/performance-profiling.md
User: "My Objective-C block callback is leaking" → See skills/objc-block-retain-cycles.md
User: "My app drains battery quickly" → See skills/energy.md
User: "Users say the device gets hot when using my app" → See skills/energy-diag.md
User: "What's the best way to implement location tracking efficiently?" → See skills/energy-ref.md
User: "Profile my app's CPU usage"
→ Use: performance-profiler agent (or /axiom:profile)
User: "How do I run xctrace from the command line?" → See skills/xctrace-ref.md
User: "I need headless profiling for CI/CD" → See skills/xctrace-ref.md
User: "My app hangs sometimes" → See skills/hang-diagnostics.md
User: "The UI freezes and becomes unresponsive" → See skills/hang-diagnostics.md
User: "Main thread is blocked, how do I diagnose?" → See skills/hang-diagnostics.md
User: "My app takes 3 seconds to launch" → See skills/app-launch.md
User: "Xcode Organizer says my launch time regressed" → See skills/app-launch.md
User: "How do I reduce pre-main / dyld time?" → See skills/app-launch.md
User: "App is slow to come up after tapping a push notification" → See skills/app-launch.md
User: "How do I write a launch performance test?" → See skills/app-launch.md
User: "How do I set up MetricKit?" → See skills/metrickit-ref.md
User: "How do I parse MXMetricPayload?" → See skills/metrickit-ref.md
User: "Scan my code for memory leaks"
→ Invoke: memory-auditor agent
User: "Check my app for battery drain issues"
→ Invoke: energy-auditor agent
User: "Audit my Swift code for performance anti-patterns"
→ Invoke: swift-performance-analyzer agent
User: "How do I inspect this variable in the debugger?" → Invoke: See axiom-build (skills/lldb.md)
User: "What's the LLDB command for conditional breakpoints?" → Invoke: See axiom-build (skills/lldb-ref.md)
User: "I need to reproduce this crash in the debugger" → Invoke: See axiom-build (skills/lldb.md)
User: "My list scrolls slowly and memory keeps growing" → See skills/memory-debugging.md first, then skills/performance-profiling.md if stutter remains
User: "App freezes for a few seconds on first launch then works fine" → See skills/hang-diagnostics.md
User: "UI locks up when multiple API calls return at the same time"
→ Cross-route: /skill axiom-concurrency (callback contention)
User: "My timer stops when the user scrolls"
→ Read: axiom-integration (skills/timer-patterns.md)
User: "EXC_BAD_INSTRUCTION crash in my timer code"
→ Read: axiom-integration (skills/timer-patterns.md)
User: "Should I use Timer or DispatchSourceTimer?"
→ Read: axiom-integration (skills/timer-patterns.md)
User: "How do I create an AsyncTimerSequence?"
→ Read: axiom-integration (skills/timer-patterns-ref.md)
User: "Review my Swift code for outdated patterns" → Invoke: See axiom-swift (skills/swift-modern.md)
User: "Is there a more modern way to do this?" → Invoke: See axiom-swift (skills/swift-modern.md)
User: "What is the app logging? I need to see console output"
→ Invoke: /axiom:console
User: "Capture the simulator logs while I reproduce this bug"
→ Invoke: /axiom:console