Skip to main content
subagent CX Codex

cpp-pro · voltagent/awesome-codex-subagents — Codex subagent: what it does, how to install

cpp-pro — a C++ subagent for memory ownership, concurrency, performance-sensitive paths, and systems integration. Use it when a change needs boundary-level analysis.

MIT ★ 6,505 updated 2026-10-05

Install into Codex · Manually: put the files in place All methods and platforms ↓
.codex/agents/cpp-pro.toml
Open on GitHub

What cpp-pro does

cpp-pro maps the execution boundary of a C++ task: its entry point, data or state flow, and external dependencies. It looks for the underlying design gap or failure cause before suggesting the smallest change that keeps unrelated behavior intact.

The subagent reviews ownership and object lifetime, RAII, exception guarantees, locks, atomics, and cross-thread access. It also checks public-header compatibility, ABI concerns, allocation and copy costs, undefined behavior, build assumptions, and compiler flags.

Its result names the module and execution boundary, explains the observed issue or risk, and separates direct validation from environment-level checks. Public API edits need a compatibility check, while inferred performance claims call for benchmarking or profiling. It avoids broad modernization and speculative micro-optimizations unless the parent agent asks for them.

What it helps with

  • trace a resource-lifetime bug
  • check a C++ path for data races
  • preserve compatibility after a public-header change
  • spot undefined behavior risks
  • review allocation and copy costs on a hot path

Example prompts for the agent

  • Inspect this C++ module for an object-lifetime problem and propose the smallest safe fix.
  • Review the concurrent execution path, identify any data-race risk, and explain the required change.
  • Check this public-header edit for ABI and interface compatibility, including its build assumptions.

How to install cpp-pro

Manually: put the files in place

.codex/agents/cpp-pro.toml

Codex defines subagents in TOML: name, description, developer_instructions. Move the Markdown text into developer_instructions by hand. For all projects use ~/.codex/agents/

Step by step, with commands for each platform: Claude Code subagents: how to create one, call it and keep context clean

Questions about cpp-pro

How do I install cpp-pro in Codex?

Place the subagent configuration at .codex/agents/cpp-pro.toml. Then assign Codex a task that needs C++ analysis.

What does cpp-pro do?

It maps a C++ task’s execution boundary, reviews ownership, concurrency, interface compatibility, and undefined-behavior risks, then gives a scoped fix with validation notes.

How does cpp-pro handle performance-sensitive code?

It checks whether allocations or copies can affect a changed path and calls for benchmarking or profiling when a performance claim is inferred. It does not add speculative micro-optimizations without a request.

Source text

cpp-pro.toml · MIT
# cpp-pro

Use when a task needs C++ work involving performance-sensitive code, memory ownership, concurrency, or systems-level integration.

Own C++ tasks as production behavior and contract work, not checklist execution.

Prioritize smallest safe changes that preserve established architecture, and make explicit where compatibility or environment assumptions still need verification.

Working mode:
1. Map the exact execution boundary (entry point, state/data path, and external dependencies).
2. Identify root cause or design gap in that boundary before proposing changes.
3. Implement or recommend the smallest coherent fix that preserves existing behavior outside scope.
4. Validate the changed path, one failure mode, and one integration boundary.

Focus on:
- ownership and lifetime boundaries across stack, heap, and shared resources
- RAII usage, exception safety guarantees, and deterministic cleanup
- concurrency safety around locks, atomics, and cross-thread object access
- ABI or interface compatibility when touching public headers
- performance-sensitive paths where allocation or copies can regress latency
- undefined behavior risks (dangling refs, out-of-bounds, data races)
- build-system and compiler-flag assumptions affecting changed code

Quality checks:
- validate success and failure paths for resource acquisition and release
- confirm thread-safety assumptions at touched synchronization boundaries
- check for accidental ownership transfer or lifetime extension bugs
- ensure any API signature changes preserve compatibility expectations
- call out benchmark or profiling follow-up when performance claims are inferred

Return:
- exact module/path and execution boundary you analyzed or changed
- concrete issue observed (or likely risk) and why it happens
- smallest safe fix/recommendation and tradeoff rationale
- what you validated directly and what still needs environment-level validation
- residual risk, compatibility notes, and targeted follow-up actions

Do not apply speculative micro-optimizations or broad modernization unrelated to the scoped defect unless explicitly requested by the parent agent.

© VoltAgent · MIT · VoltAgent/awesome-codex-subagents

Similar subagents

All subagents for Agent setup: memory, context, orchestration →

cpp-pro by other authors comes first.

cpp-pro VoltAgent Community cpp-pro is a Claude Code subagent for C++20/23 systems development, focusing on performance, template metaprogramming, and sanitizer checks. CX Codex 781installs cpp-pro Seth Hobson cpp-pro writes modern C++ from C++11 to C++23 using RAII, smart pointers, and STL algorithms. Helps with C++ refactoring and template design. CX Codex 781installs swift-code-review existential-birds swift-code-review is a Claude Code skill that checks Swift code for concurrency, error-handling, and memory issues. It activates for .swift reviews involving async/await, actors, or Sendable. CX Codex +1 253installs cpp-coding-standards affaan-m cpp-coding-standards — a skill that pushes your AI agent toward C++ Core Guidelines when it writes, reviews or refactors C++: RAII, immutability, strong typing. CX Codex +1 7,100installs qt-cpp-review qt-ai-skills qt-cpp-review reviews Qt6 C++ diffs or codebases before commits. Combines a 60-rule deterministic linter with deep agent analysis for threading, model contracts, and ownership. CX Codex +1 1,200installs m02-resource actionbook m02-resource guides AI agents in choosing the right Rust smart pointers and ownership models. Useful when designing data structures or preventing memory leaks. CX Codex +1 3,700installs modern-cpp trailofbits modern-cpp directs C++ development toward C++20/23/26 idioms, replacing dangerous raw pointers, legacy macros, and SFINAE boilerplate with memory-safe patterns. CX Codex +1 1,800installs cpp Mindrally cpp is a Claude Code skill that guides modern C++17 and C++20 coding, enforcing memory-safe practices without raw pointers, leaks, or outdated C constructs. CX Codex +1 829installs

From the same set176

The whole set →
dotnet-framework-4.8-expert dotnet-framework-4.8-expert — a Codex subagent built for maintaining legacy .NET Framework 4.8 enterprise systems, config limits, and Windows-specific dependencies. CX Codex ★ 6,505repo stars dotnet-core-expert dotnet-core-expert examines .NET and ASP.NET Core work, including API behavior, middleware, hosting configuration, and cross-platform runtime effects. CX Codex ★ 6,505repo stars django-developer django-developer — a subagent for Django projects that understands models, views, forms, ORM and middleware. Takes on tasks tied to app architecture rather than checklist execution. CX Codex ★ 6,505repo stars csharp-developer csharp-developer is a Codex subagent for C# and .NET. It makes minimal fixes to APIs, service layers, and async flows while preserving contracts and architecture. CX Codex ★ 6,505repo stars angular-architect angular-architect — a Codex subagent that owns Angular tasks involving component design, dependency injection, routing, signals, and enterprise application structure. CX Codex ★ 6,505repo stars websocket-engineer websocket-engineer handles WebSocket lifecycles, reconnect logic, message contracts, and state sync across unstable connections in Codex. CX Codex ★ 6,505repo stars ui-fixer The ui-fixer subagent applies small patches to reproduced UI bugs. Use it when the fix should stay close to the owning component and avoid unrelated refactoring. CX Codex ★ 6,505repo stars ui-designer ui-designer — a subagent that designs interfaces and interactions before coding. Delivers concrete recommendations on layout, component states, and accessibility—in a form ready to implement. CX Codex ★ 6,505repo stars

Project sponsors

Companies that keep this analytics open