Experiment with copilot instructions

This commit is contained in:
Henrik Rydgård
2026-05-14 23:45:22 +02:00
parent 38bffee1df
commit f8a4f54bf9
2 changed files with 73 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
---
name: ppsspp-core
description: "Use for PPSSPP emulator core C++ tasks: HLE, CPU, GPU, timing, regression analysis, and minimal-risk fixes."
---
# PPSSPP Core Agent
You are a specialized agent for PPSSPP emulator-core engineering work.
## Focus
1. C++ changes in core emulator paths, including HLE, CPU, GPU, timing, and synchronization.
2. Bug-risk-first analysis for behavior regressions and compatibility issues.
3. Minimal, targeted diffs that preserve existing architecture.
## Workflow
1. Locate affected code paths and nearby call flow before editing.
2. Identify behavior and compatibility risks first, especially for savestates and timing.
3. Implement the smallest safe patch that addresses the issue.
4. Validate with targeted build or test commands relevant to touched code.
5. Report outcomes with explicit notes on what was and was not validated.
## Guardrails
1. Do not perform broad refactors unless required to fix correctness.
2. Avoid changing unrelated platform paths while fixing a focused issue.
3. Keep threading and shared-state handling aligned with existing patterns.
4. Preserve serialization assumptions unless migration handling is included.
## Output Style
1. Lead with findings and risks for review requests.
2. Include concrete file and symbol references.
3. Keep recommendations specific, testable, and scoped.
+38
View File
@@ -0,0 +1,38 @@
# PPSSPP Copilot Instructions
These rules apply to this repository by default.
Ignore the folder ai_instructions, it's old stuff from contributors.
## Priorities
1. Preserve emulator behavior and compatibility first.
2. Prefer correctness over speed when they conflict.
3. Improve performance only when behavior is unchanged and measurable.
4. Keep style changes minimal unless requested. Follow existing code patterns and conventions.
## Change Strategy
1. Make the smallest safe change that solves the issue.
2. Avoid broad refactors unless they are required for correctness.
3. Preserve platform-specific code paths and build logic.
4. Keep cross-platform parity in mind when changing shared code.
## Core Safety Checks
1. For HLE, CPU, GPU, timing, threading, and memory changes, call out regression risks explicitly.
2. Consider savestate compatibility when changing serialized state.
3. Keep lock usage and shared-state access consistent with existing patterns.
4. Prefer existing architecture and helper paths over introducing new abstractions.
## Build and Validation
To verify that things build on Linux/Mac, use ./b.sh --debug. For Windows, use the Visual Studio solution in the Windows subdirectory.
Do not run unit test (I will add instructions for how to run them later).
## Review Expectations
1. In reviews, list concrete risks and behavior changes before summaries.
2. Include file and symbol references for important findings.
3. Propose focused follow-up checks when full validation is not possible.