بنقرة واحدة
rocprofsys-configure
Configure rocprofiler-systems build with CMake presets and custom options
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Configure rocprofiler-systems build with CMake presets and custom options
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Given a TheRock nightly build (URL or run-id), return the rocm-systems pin_sha used in that build
Check whether a given rocm-systems commit is included in a specific TheRock nightly build
Find the first TheRock nightly build that includes a given rocm-systems commit
Reviews Pull Requests or local diffs with an 8-agent fan-out covering static analysis, dead code, code smells + quality (naming, complexity, single-responsibility, magic numbers), language rules (C++/Python/CMake), architecture, simplification, performance (hot-path classification, allocations, locks, I/O), and undefined behaviour (signed overflow, lifetime, strict aliasing, data races, sanitizer coverage; C/C++/unsafe-Rust only). Use when the user asks to "review this PR", "review the diff", "audit this branch", "/pr-review", or when staging changes before push.
Walk through a PR review interactively, one finding at a time. Generate review via pr-review, then for each issue present analysis + proposed inline comment, let user accept/edit/skip, accumulate into a PENDING GitHub review, submit at end.
Use when user wants to list, analyze, review, or summarize GitHub PR comments on a pull request number or URL
| name | rocprofsys-configure |
| description | Configure rocprofiler-systems build with CMake presets and custom options |
Configures the rocprofiler-systems project using CMake with presets or custom options.
Use this skill when:
Prerequisites:
Check prerequisites:
cmake --version # Should be >= 3.21
gcc --version # Should be >= 7.0
ninja --version # Optional but recommended
Since rocprofiler-systems is in a monorepo and may use git worktrees, find it dynamically.
Strategy:
# Check current directory
if [ -f "CMakeLists.txt" ] && grep -q "rocprofiler-systems" CMakeLists.txt; then
PROJECT_DIR="."
# Search worktrees
elif [ -d "/home/amd/worktree/rocm-systems" ]; then
PROJECT_DIR=$(find /home/amd/worktree/rocm-systems -type d -name "rocprofiler-systems" | grep "projects/rocprofiler-systems$" | head -1)
# Ask user
else
# Use AskUserQuestion to get path
fi
Validation:
projects/rocprofiler-systems/ directory (not monorepo root)CMakeLists.txt and CMakePresets.jsonAsk user what type of build they want:
| Option | Preset | Use For |
|---|---|---|
| Debug | debug | Development with debugging symbols |
| Release | release | Production, optimized build |
| Debug-Optimized | debug-optimized | Debug symbols + optimizations |
| CI | ci | CI/CD builds with all features |
| Custom | None | User specifies all options manually |
Use AskUserQuestion to present options:
header: "Build Type"
question: "Which build configuration do you want?"
options:
- label: "Debug (Recommended for development)"
description: "Debug build with tests enabled"
- label: "Release"
description: "Optimized production build"
- label: "Debug-Optimized"
description: "Optimized with debug symbols"
- label: "CI"
description: "Full CI build configuration"
- label: "Custom"
description: "Specify options manually"
Options:
Use preset default (recommended)
build/debugbuild/releasebuild/debug-optimizedbuild/ciCustom directory
build/my-build)Ask user if they want to change default:
The project has complex dependencies. Determine which to build from source:
Key dependencies:
Strategy:
Use AskUserQuestion:
header: "Dependencies"
question: "How should dependencies be handled?"
options:
- label: "Auto-detect (Recommended)"
description: "Use system packages if available, build from source if missing"
- label: "Build all from source"
description: "Build Dyninst and all dependencies from source (slower but reliable)"
- label: "Use system packages only"
description: "Fail if system packages are missing"
If "Build from source" selected, set:
-DROCPROFSYS_BUILD_DYNINST=ON
-DROCPROFSYS_BUILD_TBB=ON
-DROCPROFSYS_BUILD_BOOST=ON
-DROCPROFSYS_BUILD_ELFUTILS=ON
-DROCPROFSYS_BUILD_LIBIBERTY=ON
Ask about optional features:
| Feature | CMake Option | Default |
|---|---|---|
| Python support | ROCPROFSYS_USE_PYTHON | ON |
| MPI support | ROCPROFSYS_USE_MPI | OFF |
| PAPI hardware counters | ROCPROFSYS_USE_PAPI | ON |
| Testing | ROCPROFSYS_BUILD_TESTING | ON |
Only ask if user selected "Custom" or explicitly wants to change features.
With preset:
cd /path/to/projects/rocprofiler-systems
cmake --preset <preset-name>
With custom options:
cd /path/to/projects/rocprofiler-systems
cmake -B <build-dir> \
-DCMAKE_BUILD_TYPE=<Debug|Release|RelWithDebInfo> \
-DCMAKE_INSTALL_PREFIX=/opt/rocprofiler-systems \
-DROCPROFSYS_BUILD_DYNINST=<ON|OFF> \
-DROCPROFSYS_BUILD_TBB=<ON|OFF> \
-DROCPROFSYS_BUILD_BOOST=<ON|OFF> \
-DROCPROFSYS_USE_PYTHON=<ON|OFF> \
-DROCPROFSYS_BUILD_TESTING=<ON|OFF> \
-G Ninja
Show configuration command to user before running.
After CMake runs, check for:
Configuration success
Expected features enabled
Common warnings
Report to user:
rocprofsys-build skillcd /path/to/projects/rocprofiler-systems
cmake --preset debug
cd /path/to/projects/rocprofiler-systems
cmake --preset release \
-DROCPROFSYS_BUILD_DYNINST=ON \
-DROCPROFSYS_BUILD_TBB=ON \
-DROCPROFSYS_BUILD_BOOST=ON \
-DROCPROFSYS_BUILD_ELFUTILS=ON \
-DROCPROFSYS_BUILD_LIBIBERTY=ON
cd /path/to/projects/rocprofiler-systems
cmake -B build/my-custom-build \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DCMAKE_INSTALL_PREFIX=$HOME/rocprofsys-install \
-DROCPROFSYS_BUILD_DYNINST=ON \
-DROCPROFSYS_BUILD_TBB=ON \
-DROCPROFSYS_BUILD_BOOST=ON \
-DROCPROFSYS_USE_PYTHON=ON \
-DROCPROFSYS_USE_MPI=ON \
-DROCPROFSYS_BUILD_TESTING=ON \
-G Ninja
This skill produces:
build/<preset>/CMakeCache.txtTypical output structure:
projects/rocprofiler-systems/
└── build/
└── debug/ # Or release, debug-optimized, etc.
├── CMakeCache.txt
├── CMakeFiles/
├── build.ninja # If using Ninja
└── ...
| Mistake | Fix |
|---|---|
| Configuring in wrong directory | Must be in projects/rocprofiler-systems/, not monorepo root |
| Using monorepo build directory | Build dir must be inside the project, not at monorepo level |
| Missing dependencies | Use -DROCPROFSYS_BUILD_<DEP>=ON to build from source |
| CMake version too old | Install CMake 3.21+: pip install --user cmake |
| In-source build | Always use out-of-source: -B build/... |
| Forgetting generator | Specify -G Ninja for faster builds |
| Not checking configuration output | Always review CMake output for warnings |
Solution:
cmake --preset debug -DROCPROFSYS_BUILD_DYNINST=ON \
-DROCPROFSYS_BUILD_TBB=ON \
-DROCPROFSYS_BUILD_BOOST=ON \
-DROCPROFSYS_BUILD_ELFUTILS=ON \
-DROCPROFSYS_BUILD_LIBIBERTY=ON
Solution:
pip install --user cmake==3.21.0
export PATH=$HOME/.local/bin:$PATH
Symptom: CMakeLists.txt doesn't mention rocprofiler-systems
Solution: Navigate to projects/rocprofiler-systems/ subdirectory within monorepo
Steps:
| After Configuration | Use |
|---|---|
| Build configured | rocprofsys-build to compile |
| Need to reconfigure | Remove build directory, run this skill again |
| Configuration failed | Check docs, install deps, try again |
projects/rocprofiler-systems/, not the monorepo root-D flags