mirror of
https://github.com/MoleskiCoder/EightBitNet.git
synced 2026-10-24 14:05:42 +00:00
Fix up 6502 test classes
This commit is contained in:
1 parent
bb626b9e9e
commit
284158247b
3 files changed
+5
-5
No files matched your search
@@ -17,7 +17,7 @@ namespace M6502.Test
|
||||
private readonly Ram ram = new(0x10000);
|
||||
private readonly Symbols.Parser symbols = new();
|
||||
private readonly Disassembler disassembler;
|
||||
private readonly Profiler profiler;
|
||||
private readonly Profiler<MOS6502> profiler;
|
||||
private readonly MemoryMapping mapping;
|
||||
|
||||
private readonly Register16 oldPC = new((ushort)Mask.Sixteen);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net9.0</TargetFramework>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<GenerateDocumentationFile>False</GenerateDocumentationFile>
|
||||
|
||||
+3
-3
@@ -2,14 +2,14 @@
|
||||
{
|
||||
using System.Diagnostics;
|
||||
|
||||
public sealed class Profiler
|
||||
public sealed class Profiler<TProcessor> where TProcessor : Core
|
||||
{
|
||||
private readonly long[] instructionCounts = new long[0x100];
|
||||
private readonly long[] instructionCycles = new long[0x100];
|
||||
private readonly Dictionary<int, long>[] addressCycleDistributions = new Dictionary<int, long>[0x10000]; // Addresses -> cycles -> counts
|
||||
private readonly Dictionary<int, long> scopeCycles = []; // ID -> Cycles
|
||||
|
||||
private readonly MOS6502 processor;
|
||||
private readonly TProcessor processor;
|
||||
private readonly Disassembler disassembler;
|
||||
private readonly Symbols.Parser symbols;
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
private long totalCycles = -1;
|
||||
private bool totalCyclesValid;
|
||||
|
||||
public Profiler(MOS6502 processor, Disassembler disassembler, Symbols.Parser symbols, bool activate)
|
||||
public Profiler(TProcessor processor, Disassembler disassembler, Symbols.Parser symbols, bool activate)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(processor);
|
||||
ArgumentNullException.ThrowIfNull(disassembler);
|
||||
|
||||
Reference in new issue
Block a user