6502 by dbhqGitHub

· All entries

The NES's mutation pass, and the known differences checked

Task 16 of the NES plan has five steps. This entry is the first two: the mutation pass, and the check of docs/known-differences.md. The third, the issues for what is left out, was done in task 15. The final review and the report to Dan are the controller’s.

The mutation pass

How. One fault at a time, in a scratch copy outside the repository: git archive HEAD | tar -x -C /tmp/nes-mutation, the repository’s .testdata linked in, and a throwaway git there to put the code back between faults. Each fault was a single exact replacement, checked to match once, applied by a small script; then the NES test project was built and run in two halves, the project’s own tests and the tests that run third-party or bundled ROMs:

cd /tmp/nes-mutation && git checkout -- . && <apply one fault>
dotnet build tests/Dbhq.Machines.Nes.Tests -c Release -v q
dotnet test tests/Dbhq.Machines.Nes.Tests -c Release --no-build \
  --filter "FullyQualifiedName!~BlarggTests&FullyQualifiedName!~NesAcceptanceTests&FullyQualifiedName!~NestestOnTheBus&FullyQualifiedName!~BootTests"
dotnet test tests/Dbhq.Machines.Nes.Tests -c Release --no-build \
  --filter "FullyQualifiedName~BlarggTests|FullyQualifiedName~NesAcceptanceTests|FullyQualifiedName~NestestOnTheBus|FullyQualifiedName~BootTests"

The first half is called “unit” below: 1,176 tests in about 6 seconds, the chip tests written from the fact sheets. It includes NesLoaderTests, two of whose tests compare the homebrew’s boot frame with its recorded hash; only faults 24a and 24b reached them, and both were caught by a PpuBackgroundTests test too. The second half is called “ROM”: 320 tests in about a minute, Blargg’s and the other community ROMs (BlarggTests, and NesAcceptanceTests, which runs them again with the rest of the table), nestest on the bus, and the homebrew’s boot. Both halves ran for every fault, not only until one test failed, so the table says which ROMs see each fault as well as which unit tests.

When. 6 October 2026, from 03:28 to 04:55 UTC, on the shared machine, one fault after another. The one-minute load at the start and end of each fault’s run was between 0.47 and 27.40; it was over 6 only while faults 26 and 27a ran (27.40 at 04:16 and 9.31 at 04:19), when another job took the machine for a few minutes. The load changes how long a run takes, not what it finds, since the machine is deterministic.

The table. Each fault is one change; the third column gives the line and the change, or its location where the change is a value in a table, in src/Dbhq.Machines.Nes/ at commit d70aedf. “Unit” and “ROM” are the failing tests of each half. Where a theory has a row per region or parameter, each row counts.

#Fault plantedWhere, before, afterUnitROMUnit tests that caught itROMs that caught it
1The PAL accumulator’s denominator 5 made 6 (NTSC, with remainder 0, unchanged)NesBus.cs:140 _dotDenominator = region.DotsDenominator;, + 1 added154NesBusTests: ThePalDotsRunThreeThreeThreeThreeFour, EachReadOrWriteIsOneCycleAndTheDotsFollowTheRegionsRatio, the NMI boundary rows; OamDmaTests.ThePpuRunsThroughTheStallAtTheRegionsRationestest (PAL), the homebrew’s boot (PAL)
2aThe odd-frame skip on PAL tooPpu.cs:419 _dropDot = _oddFrame && _oddFrameSkipsADot && RenderingEnabled;, _oddFrameSkipsADot removed20PpuTimingTests: TheDroppedDotIsDecidedWhenDot338OfThePreRenderLineRuns, AFrameIsLinesTimes341DotsLessOneOnAnOddNtscFrameWithRenderingOn (both PAL)none: no PPU timing ROM runs on PAL
2bThe odd-frame skip with rendering off toothe same line, && RenderingEnabled removed426PpuTimingTests.WithRenderingOffEveryFrameIsWhole, TheDroppedDotIsDecided...; NesBusTests.WithRenderingOffThePpusFrameLineAndDotAreTheBussDotCountnine of the ten ppu_vbl_nmi singles (not 04) and the combined ROM, cpu_interrupts_v2 2, mmc3_test_2 4
3The VBlank flag set one dot earlyPpu.cs:398 if (_dot == 1) made if (_dot == (_line == VblankLine ? 0 : 1))2418PpuTimingTests (the flag’s dot, suppression, the NMI output), NesBusTests (the NMI boundary, the read on the flag’s dot)ppu_vbl_nmi 02, 03, 06, 07, 10, cpu_interrupts_v2 2, mmc3_test_2 4
4The sprite overflow bug removed: each later sprite’s Y checked straightPpuSprites.cs:72 _evaluationM = (_evaluationM + 1) & 3; removed44PpuSpriteTests.WorkedExample6_TheOverflowBugsFalsePositive, ...FalseNegativesprite_overflow_tests 3 and 4
5A pulse duty entry: 25 per cent one step lateApuChannels.cs:177 [0x02, 0x06, 0x1E, 0xF9] made [0x02, 0x0C, 0x1E, 0xF9]20PulseTests.EachDutyStepsThroughItsEightOutputsOneStepEveryTimerPeriodnone
6The noise table’s PAL entry 9, 236 made 254Region.cs:8410RegionTests.TheNoisePeriodsAreApuSection7none
7The frame counter’s first PAL step, 8313 made 8314Region.cs:8610RegionTests.TheFrameCounterListsAreTheRowsOfApuSection10none
8aThe DMC rate for index 5 on NTSC, 254 made 252Region.cs:6714RegionTests.TheDmcRatesAreApuSection8apu_test 8-dmc_rates and the combined ROM
8bThe DMC rate for index 5 on PAL, 236 made 238Region.cs:8510RegionTests.TheDmcRatesAreApuSection8none: no DMC rate ROM runs on PAL
9MMC1’s back-to-back write no longer ignoredMappers/Mmc1.cs:72 _sinceWrite == 1 made _sinceWrite == -140Mmc1Tests: AWriteOnTheCycleAfterAWriteIsIgnored, ARunOfConsecutiveWritesTakesOnlyTheFirst, ARealIncOnTheCpuLoadsOneBitNotTwo, the bus RMW testnone
10aMMC3’s A12 filter 3 cycles made 2Mappers/Mmc3.cs:54 FilterCycles = 3 made 2118Mmc3Tests.TheFilterCountsARiseOnlyAfterA12HasBeenLowForThreeCycles, four Mmc3ScanlineCounterTestsmmc3_test_2 2 and 4, mmc3_irq_tests 2 and 4
10bMMC3’s A12 filter made 4the same line, 430Mmc3Tests.TheFilterCounts..., Mmc3ScanlineCounterTests.TheBoardIsToldTheBusCycleOfEachPpuAccessnone
11OAM DMA’s extra cycle on the other parity (reads on puts, writes on gets)NesBus.cs:411 and 416, get and !get swapped168OamDmaTests (513 and 514, the stall, no fetch in it), DmcDmaTests.AFetchInsideOamDmaCostsTwoAndAtItsEndOneOrThreeboth sprdma_and_dmc_dma ROMs, cpu_interrupts_v2 4 and the combined ROM
12The controller’s read order: A with B, Select with Start, Up with Down, Left with RightController.cs:66 and 77, _reads made _reads ^ 131013 ControllerTests, OamDmaTests and DmcDmaTests (the halt on a pad read)none: no pinned ROM reads a pad
13The PAL palette’s emphasis swap removedRegion.cs:88 emphasisSwapsRedAndGreen: true made false20RegionTests.OnlyThePalPictureChipSwapsRedAndGreenInEmphasis, PpuBackgroundTests.ThePalPpuEmphasisesWithItsRedAndGreenBitsSwappednone
14DMC DMA without its dummy cycle (2 or 3 stolen, not 3 or 4)NesBus.cs:434 dmc++; made dmc = 3;1810seven DmcDmaTestsdmc_dma_during_read4 dma_2007_read, dma_2007_write, dma_4016_read; both sprdma_and_dmc_dma
15The $4017 write delay’s parity swappedApu.cs:329 ? 3 : 4 made ? 4 : 3264seven FrameCounterTestscpu_interrupts_v2 4 and the combined ROM
16aThe IRQ line taken at the end of the cycle (the sound unit and the board)NesBus.cs:342 _cpu.Irq = irq; made _cpu.Irq = _apu.Irq || (_mapperCanInterrupt && _mapper.Irq);614NesBusTests.TheFrameIrqReachesTheCpuInTheCycleAfterTheOneThatSetIt, two Mmc3ScanlineCounterTestspal_apu_tests and blargg_apu_2005 08.irq_timing, cpu_interrupts_v2 3 to 5, mmc3_test_2 4
16bThe NMI line taken at the end of the cycleNesBus.cs:341 _cpu.Nmi = nmi; made _cpu.Nmi = _ppu.Nmi;1212NesBusTests: the NMI boundary, EnablingNmiDuringVblankIsTakenAfterTheNextInstruction, the read on the flag’s dotppu_vbl_nmi 04 and 05, cpu_interrupts_v2 2 and 3
17Pulse 1’s sweep negating like pulse 2’sApu.cs:95 onesComplement: true made false20PulseTests.TheNegatesDifferPulseOneTakesOneMorenone
18The triangle’s linear reload flag cleared with the control bit setApuChannels.cs:451 to 454, if (!_control) dropped42TriangleTests.WithTheControlFlagSetTheLinearCounterReloadsEveryQuarterFrame, ALinearCounterOfZeroStopsTheSequencerAndTheOutputHoldsItsValueapu_mixer triangle
19Sprites’ left-edge clipping ignoredPpu.cs:802 ? 0 : 8 made 022PpuSpriteTests.WithPpumaskBit2ClearSpritesAreHiddenInTheLeftmostEightPixelssprite_hit_tests 05.left_clip
20Sprite 0 hit at x = 255Ppu.cs:1005 && x != 255 removed24PpuSpriteTests.WorkedExample5_NoHitAtColumn255sprite_hit_tests 06.right_edge, 11.edge_timing
21aThe latch decay 600 ms made 60 msPpu.cs:258 0.6 made 0.0660six PpuRegisterTests (TheLatchKeepsItsBitsForHalfASecond and the refreshes)none
21bThe latch decay made 6 sthe same line, 6.054PpuRegisterTests.ALatchBitNotRefreshedForMoreThanTheDecayTimeReadsZero and three moreppu_open_bus (both regions)
22MMC3’s PRG bank mode invertedMappers/Mmc3.cs:204 != 0 made == 0100seven Mmc3Testsnone
23UxROM’s fixed bank the second-lastMappers/Uxrom.cs:51 Prg16Count - 1 made - 260three UxromTestsnone
24aOne attribute shift: coarse Y bit 0 in place of bit 1PpuBackground.cs:89 (_v >> 4) & 4 made (_v >> 3) & 445PpuBackgroundTests.CoarseYScrollRunsOnIntoTheNametableBelowAfterRow29, the boot hash in NesLoaderTeststhe homebrew’s boot (both regions)
24bOne attribute shift: coarse X bit 0 in place of bit 1the same line, _v & 2 made (_v << 1) & 256513 PpuBackgroundTests, the boot hashthe homebrew’s boot
25$2007 read with no buffer delayPpu.cs:484 and 485 swapped516PpuRegisterTests.WorkedExample3_TheReadBufferDelays... and three more in PpuRegisterTests and NesBusTestsppu_read_buffer, cpu_dummy_writes_ppumem, three dmc_dma_during_read4 ROMs, and double_2007_read no longer fails as written down
26PRG RAM cleared by the reset buttonafter NesBus.cs:281, _mapper.ClearPrgRam(); added86NesBusTests.ResetKeepsRamAndPrgRamAndTheCpuResetsAgain, the six battery rows, Mmc1Tests (power on and reset)NesAcceptanceTests’ PRG RAM rule, all six mappers
27a8x16 sprites’ table from PPUCTRL bit 3, not tile bit 0PpuSprites.cs:186 (_fetchTile & 1) << 12 made (_ctrl & 0x08) << 940PpuSpriteTests.In8By16ModeBit0OfTheTileChoosesTheTableAndAVerticalFlipSwapsTheHalvesnone
27b8x16 sprites’ tile bit 0 not clearedPpuSprites.cs:185 (_fetchTile & 0xFE) made _fetchTile40the same testnone
28The power-on dot phase moved (a faulty fault: see below)NesBus.cs:253 _dotAccumulator = 0; made = 2;94NesBusTests (NTSC rows)nestest (both)
28bThe PAL power-on dot phase moved, NTSC untouchedthe same line, = _dotDenominator > 2 ? 2 : 0;02nonenestest (PAL) only
28cPower on leaving the dot accumulator where it wasthe same line removed00none (run with the new test in: it alone failed)none
29One dot before the access, not twoNesBus.cs:102 DotsBeforeAccess = 2 made 1216NesBusTests.AStatusReadOnTheDotTheFlagIsSetOrTheNextReadsItAndStopsTheNmippu_vbl_nmi 05 to 08, cpu_interrupts_v2 2, mmc3_test_2 4
30The 2A07’s DMC DMA repeating the halted readRegion.cs:89 dmcDmaRepeatsHaltedRead: false made true20DmcDmaTests’ two “on NTSC only” tests, PAL rowsnone
31Power-on RAM $FF, not $00NesBus.cs:249 Array.Clear(_ram); made Array.Fill(_ram, (byte)0xFF);324NesBusTests.PowerOnClearsRam..., and four more NesBusTests and OamDmaTests tests whose programs ran differently with RAM at $FFnestest (both)
32The odd-frame drop decided at dot 337Ppu.cs:99 338 made 33714PpuTimingTests.TheDroppedDotIsDecidedWhenDot338OfThePreRenderLineRunsppu_vbl_nmi 10 and the combined ROM
33MMC3 as the other (NEC) revisionMappers/Mmc3.cs:165 to 175, the IRQ only on a count down to 0 or a requested reload148Mmc3Tests (both latch 0 tests), five Mmc3ScanlineCounterTestsmmc3_test_2 5, mmc3_irq_tests 6; and the two known failures stop failing as written
34$4017 with the inhibit bit not clearing the frame IRQ flagApu.cs:323 to 326 removed254FrameCounterTests.SettingTheInhibitBitClearsTheFlagAndKeepsItClearthe APU’s IRQ and timing ROMs in all three suites, cpu_interrupts_v2, every MMC3 IRQ ROM, instr_test-v5 16-special
35Noise mode 1 tapping bit 5ApuChannels.cs:528 ? 6 : 1 made ? 5 : 120NoiseTests.ModeOneFromOneGivesTheSheetsSequencenone
36OAM attribute bits 4 to 2 keptPpu.cs:531 the & 0xE3 dropped128PpuRegisterTests.Oam2003And2004..., OamDmaTests, DmcDmaTestsoam_stress, ppu_open_bus (both regions)
37The DMC load’s delay parity swappedApuChannels.cs:719 ? 3 : 4 made ? 4 : 3108three DmcDmaTestsdma_2007_read, dma_4016_read, both sprdma_and_dmc_dma
38A DMC reload halting from the put after nextApuChannels.cs:795 cycle + 2 made cycle + 400nonenone
39The length table’s entry 14, 26 made 24ApuChannels.cs:2248PulseTests.EveryLengthTableEntryLoadslen_table in apu_test, pal_apu_tests and blargg_apu_2005
40A $2002 read one dot before VBlank no longer suppressing itPpu.cs:457 true made false26PpuTimingTests.AStatusReadOneDotBeforeTheFlagIsSet...ppu_vbl_nmi 02, 06 and the combined ROM
41The sprite priority bit ignoredPpu.cs:1011 || true added40two PpuSpriteTests on prioritynone
42A $4015 read clearing the DMC’s IRQ flag tooafter Apu.cs:255, a call that clears it24DmcTests.ASampleThatEndsWithIrqEnabledSetsTheFlagAndHoldsTheLineapu_test 7-dmc_basics and the combined ROM
43Writing 0 to $4016 with the strobe low reloading the padController.cs:40 high || _strobe made high || !high20ControllerTests.AWriteOfZeroToTheStrobeWhileItIsAlreadyLowDoesNotReloadnone
44OAMADDR not cleared on dots 257 to 320Ppu.cs:964 removed20PpuSpriteTests.DuringRenderingOamaddrIsClearedOnDots257To320...none
45MMC1’s PRG register bit 4 not switching PRG RAM offMappers/Mmc1.cs:159 made PrgRamEnabled = true;10Mmc1Tests.ThePrgRamIsAtSixThousandAndTheBankRegisterCanDisableItnone
46CNROM’s bus conflict removedMappers/Cnrom.cs:39 made SetChr8(value);20two CnromTestsnone
47A $4015 read putting its value on the CPU’s open busNesBus.cs:457 the value kept in _openBus00nonenone

Rows 1 to 13 are the plan’s list; 14 to 27 the further ones the task named; 28 to 47 this pass’s own, chosen at the seams the others do not reach: the power-on and reset state, the order inside a cycle, the PPU’s odd-frame and suppression dots, the DMA’s halts, and the boards’ smaller rules.

Fault 28 was a faulty fault. Starting the accumulator at 2 was meant to move PAL’s fourth dot, but on NTSC the accumulator’s denominator is 1 and the code counts on it staying under that, so it broke NTSC too, which is what the unit tests caught. 28b is the fault as it was meant, PAL only.

The totals. Of the 56 faults, 52 were caught by the unit tests: 51, and fault 28, the faulty one above. One more, 28b, was caught only by a ROM, and three by nothing.

Four were not caught by the unit tests.

  • 28b, the PAL power-on phase, was seen only by nestest’s log on PAL. The unit test for the 3, 3, 3, 3, 4 pattern runs on a bus that was never powered on, whose accumulator starts at zero because a new field does, so it never saw PowerOn set it. known-differences.md said the tests check the phase, which was true only through nestest.
  • 28c, a second power on keeping the old phase, was seen by nothing: each ROM runs on a new machine, and every power-on test powers on once.
  • 38, a DMC reload halting two cycles later, was seen by nothing. The ROMs synchronise themselves to the DMC and test the cost and the parity, as the known differences already said, and the unit tests measured the cost and the parity too, never the delay.
  • 47, a $4015 read changing the CPU’s open bus, was seen by nothing. The bus’s comment and bus.md 3 both say that read leaves the bus alone, and no test read the bus straight after it.

What was done about them. Each now has a test, in the project, that fails on its fault and passes on the code as it stands (checked both ways, the new tests alone, against each fault):

FaultNew testOn the fault
28b, 28cNesBusTests.PowerOnPutsThePalFourthDotInEveryFifthCycleCountedFromPowerOnfails
38DmcDmaTests.AReloadHaltsOnTheNextPutAfterTheOutputClockThatEmptiedTheBuffer (both regions)fails on both
47NesBusTests.AReadOf4015LeavesTheOpenBusAsItWas (both regions)fails on both

The test for 38 pins the model’s choice, not the chip: when in its APU cycle the hardware schedules a reload is not on the sheet, and the entry in known-differences.md now says the test holds the choice. It watches the DMC’s level, which moves on every output clock with bytes of $AA, to find the clock that ended a byte, and checks the halt is on the next put, two cycles later.

One more test came from the known-differences check below, not from a fault: NesBusTests.TheFirstVblankFlagIsSetInTheCycleThatRunsLine241Dot1, which holds the “cycle 27395” that known-differences.md gave with nothing behind it, and PAL’s 25683. It also fails on fault 3, the flag a dot early.

One fault was caught by a community ROM alone, 28b, by nestest’s log on PAL, and none by a Blargg ROM alone. The other way round is the more telling: 22 of the 56 faults (2a, 5, 6, 7, 8b, 9, 10b, 12, 13, 17, 21a, 22, 23, 27a, 27b, 30, 35, 41, 43, 44, 45, 46) were caught by the project’s own tests and by no ROM. The ROMs do not read the pads, do not run PPU timing on PAL, do not reach the PAL tables, and do not test the boards’ smaller rules; for those the chip tests from the fact sheets are the only guard. Several of those are held by a single test: the PAL tables only by RegionTests’ comparison with the sheet, the odd-frame decision dot only by TheDroppedDotIsDecidedWhenDot338OfThePreRenderLineRuns and ppu_vbl_nmi 10.

A finding about the code: none. No fault survived because the code was wrong in the same way, and the pass found no defect in the machine. The pass changed no line in src/; the final fix wave later corrected comments there, below.

The known differences, checked

docs/known-differences.md was read against the list the plan’s task gives and the list the controller’s brief added, and every [guessing - verify] left in docs/nes/facts/ was followed to an entry or a stated resolution (grep -rn -i "guessing" docs/nes/facts/*.md: 24 lines when the check ran, 23 once cartridge.md’s settled open item lost its tag).

Already there, with a cause and a test or ROM: RAM at power on and the PPU’s power-on alignment; the PAL fourth dot’s power-on phase; the latch’s one decay time and ppu_open_bus; PAL using the NTSC colours; every community known failure with its entry (the two $AB ROMs on both regions and the LXA decision, double_2007_read, the two MMC3 ROMs of the other revision); the MMC3 revision chosen; the 2A07’s DMC DMA guess; the $4017 parity; MMC1’s and the other boards’ reset; UxROM’s and AxROM’s submapper 2 and CNROM’s AND.

Added, each with its cause and the test or ROM that shows it:

  • The reset button leaves the PAL phase where it was, in the bus section: the PPU goes back to line 0 dot 0 and the accumulator does not, which a test uses on purpose to move the cycles against the dots.
  • On PAL the flags clear at dot 1 of line 311, implied by 70 lines of VBlank and not confirmed (timing.md open item 1), the one sheet guess with no entry.
  • The colours were never compared with a real PAL television or a capture of one, and which tests do hold them.
  • Not run, and why: nmi_sync (the readme says to look at the picture, and no frame check was written) and dmc_tests (a sound to listen to, no readme, no source).
  • Every known failure in one place, pointing to its entry.
  • A new section, the cartridge file and the page: the iNES TV system bit not read, the Dendy refused, the 4 MB file cap and the 64 KB RAM caps, and the picture shown whole, 256 by 240, in the region’s pixel shape (8:7 on NTSC).
  • The open bus’s $4015 exception now names its test, and the bus section no longer says there are no bus conflicts at all, since the boards have their AND.

Hand-typed figures tied to a test or a dated command (AGENTS.md rule 5): the first VBlank’s cycle 27395 to the new test; the sound unit’s “72 dB or more” and the DMC section’s “89.6 dB” to what ResamplerTests holds, more than 65 dB, with the figures it printed this morning quoted with the date and the command; the mixer’s “within 1e-7” corrected to the 1e-6 that MixerTests holds; and the 8-cycle mean’s “under 0.25 dB at 20 kHz” replaced by the formula it follows from. Four comments in the source carried the same figures: ApuMixer.cs (the 1e-7), TriangleChannel in ApuChannels.cs (the 72 dB), and SampleBuffer.cs (the 0.25 dB, and the -55 and -72 dB of the kernel’s phases). In the final fix wave of 6 October 2026 each was put right the same way: the line a test holds, or the dated task 9 run and its command, or the formula. In the same wave the sample buffer’s exception notes were corrected to the rule its code applies, a sample rate no higher than an eighth of the CPU clock.

Every guess in the fact sheets has an entry or a resolution. Of the 23 lines, one is the README’s definition of the tag. The rest: cartridge.md’s “which ROMs run on PAL” was settled in task 12 by each ROM’s readme or source (the journal entry of 5 October), and its open item now says so; ppu.md’s rendering toggle delay, the evaluation’s start at sprite 0 and greyscale have entries; apu.md’s PAL pulse under 8 has one; timing.md’s first VBlank, the PAL fourth dot and now the PAL clear have them; bus.md’s 2A07 DMA has one; and every mappers.md guess (MMC1’s PRG RAM, CNROM, the boards’ reset, MMC3’s power on, the bus after rendering, the pre-render line’s second clock) has one.

The issues

The parts left out (task 16 step 3) were filed in task 15 as issues 61 to 69, and the NES page links each from its list: the Dendy (#61), the Famicom Disk System (#62), expansion audio (#63), the Zapper and other peripherals (#64), unlicensed mappers (#65), the battery-RAM save (#66), the picture’s analogue quirks (#69); the speed (#67) and the 3D models (#68, which names the branch feat/nes-models) are linked from the page’s text. None is missing.

After the review: LXA on the Ricoh 2A03 is $FF

Decided by Dan, 6 October 2026, after the final report: the Ricoh 2A03 variant’s LXA ($AB) uses $FF, the console-calibrated value Blargg’s instr_test-v5 passes with, and $AB is left out of the nes6502 Harte run. The NMOS 6502 and the other variants keep $EE, as Harte’s data has it. This is the road the decision of 5 October left open (the entry of that day, task 12).

The change. One constant in the core, _lxaConstant, set in Cpu’s constructor from the variant, so the instruction reads a field and tests no variant; Cpu.Nmos.cs says why LXA differs from ANE there. The core’s tests: CpuTests.LxaOrsAWithTheVariantsConstantAndAndsTheOperand, five values of A and the operand on each of the two NMOS variants, failed in three of its Ricoh 2A03 cases before the change and passes after it. The Harte exclusion is a list with reasons, Coverage.Excluded, beside the two WDC opcodes whose files are empty, and CoverageTests prints each variant’s count of opcodes run and excluded, so it is not a silent skip. It also runs the nes6502 $AB file on the NMOS variant: all 10,000 cases pass there, so the cycles, the bus accesses and the flags of the 2A03’s LXA are still checked against Harte’s data, and only the constant is not. On the NES side, the two ROMs moved from the known failures to the passing table, and all_instrs prints “All 16 tests passed” on both regions. Three known failures remain: double_2007_read and the two MMC3 ROMs of the other revision.

The checks (6 October 2026, 13:45 to 14:16 UTC, load 2.4 to 38):

  • cd site && npm run results, which runs dotnet test --configuration Release over the solution: the core 1,608 passed, the KIM-1 39, the BBC Micro 980, the NES 1,503, none failed. The Harte suites: Nmos6502Harte, Synertek65C02Harte and Rockwell65C02Harte 256 each, Ricoh2A03Harte 255 (one fewer than before, the exclusion), Wdc65C02Harte 254.
  • The NES differential (bench/nes-speed/differential) on 18cc4ec, exported, and on the change: of the 254 runs, every one is identical but instr_test-v5/rom_singles/03-immediate on each region, the ROM that now passes. all_instrs does not reach $AB in the differential’s 150 frames.
  • The core’s speed, bench/thread-time core 5 (Dormann’s test on the NMOS variant), the baseline export and the change in turn, eight processes each (13:40 to 13:46 UTC, load 5 to 45): median of the medians 10.97 ns a cycle before and 11.11 after, with the processes’ medians from 10.0 to 12.0 before and 9.4 to 12.9 after. That is inside the noise; Dormann’s test never runs $AB, so the field the change added is never read on that path.