You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/copilot-instructions.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,10 +40,12 @@ dotnet build
40
40
# Run with executable
41
41
dotnet run --project src/Spice86 -- -e path\to\program.exe
42
42
43
-
# Run tests
44
-
dotnet test tests/Spice86.Tests
43
+
# Run tests (excluding SingleStepTest - see note below)
44
+
dotnet test tests/Spice86.Tests --filter "FullyQualifiedName!~SingleStepTest"
45
45
```
46
46
47
+
> **SingleStepTest exclusion rule**: `SingleStepTest` runs millions of CPU instruction test cases and take an extremely long time to complete. **Always exclude it** using `--filter "FullyQualifiedName!~SingleStepTest"` unless the change being tested directly touches CPU instruction decoding, execution, or flag handling (e.g. changes to `CfgCpu`, instruction parsers, ALU operations, or flag computation). When in doubt, exclude it.
48
+
47
49
### Debugging Workflow
48
50
-**GDB Integration**: Server runs on port 10000 by default (`--GdbPort 10000`)
49
51
- Use `--Debug` to pause at startup for breakpoint setup
-**Function Tracking**: `FunctionHandler` intercepts calls/rets for CFG building and override dispatch
243
244
244
245
## Common Gotchas
245
-
-**Segmented addressing**: Use `SegmentedAddress` not raw offsets; linear address = segment * 16 + offset
246
+
-**Segmented addressing**: Use `SegmentedAddress` not raw offsets; linear address = segment * 16 + offset. Avoid computing addresses from `SegmentedAddress.Linear` because segmented addresses can roll over and `.Linear` does not handle this correctly. Use the `IMmu` (`TranslateAddress`) for address translation instead, as it handles rollover and access validation. Passing `.Linear` to an API that already expects a linear address is fine.
246
247
-**A20 Gate**: Memory wrapping at 1MB boundary controlled by `A20Gate` (toggle via `--A20Gate` flag)
247
248
-**EMS/XMS**: Enabled by default; disable with `--Xms false` / `--Ems false`
248
249
-**Time handling**: Real-time vs instruction-based via `--InstructionTimeScale` or `--TimeMultiplier`
Copy file name to clipboardExpand all lines: src/Spice86.Core/Emulator/OperatingSystem/DosPathResolver.cs
+46-45Lines changed: 46 additions & 45 deletions
Original file line number
Diff line number
Diff line change
@@ -286,46 +286,12 @@ internal DosPathBuilderResult GetFullDosPathIncludingRoot(string? dosPath, out s
286
286
/// <param name="dosPath">The DOS path to convert.</param>
287
287
/// <returns>A string containing the full file path in the host file system, or <see langword="null"/> if nothing was found or the DOS path cannot be resolved.</returns>
@@ -377,6 +343,29 @@ internal DosPathBuilderResult GetFullDosPathIncludingRoot(string? dosPath, out s
377
343
/// <param name="dosPath">The DOS path to convert.</param>
378
344
/// <returns>A string containing the full file path in the host file system, or <see langword="null"/> if nothing was found or the DOS path cannot be resolved.</returns>
0 commit comments