{
  "schemaVersion": "site.evidence-summary/1",
  "kind": "cpu-differential-other-core",
  "recorded": "2026-11-21",
  "sourceRevision": "287d49a4a6b9254b66f5a8f12637a53945bee637",
  "cleanTree": true,
  "dirtyTree": false,
  "treeStateBasis": "The source record carries the provenance block of the clean re-record: dirtyTree false at this revision.",
  "note": "The suite recorder refuses this core, so the record is written from the log of the clean-tree runs by a helper script (the record says so).",
  "provenance": {
    "sourceRevision": "287d49a4a6b9254b66f5a8f12637a53945bee637",
    "dirtyTree": false,
    "cleanTree": true,
    "checks": "provenance check \"clean tree at 287d49a4a6b9254b66f5a8f12637a53945bee637\" passed before and after each of the 2 recording runs"
  },
  "source": {
    "repoPath": "eval-results/stm8-differential.json",
    "sha256": "117983692b6b0dd61582b7bebb80fca1be93a70a41f78ee4470c97ff22d24b3a",
    "commit": "d02ef5052b25be3d0848eefe5b86031e9a3e5c19"
  },
  "core": "STM8",
  "reference": {
    "name": "ucsim sstm8 (from SDCC 4.2.0)",
    "version": "0.6.4"
  },
  "runs": [
    {
      "test": "stm8_streams_agree_with_the_reference",
      "profile": "stm8",
      "basis": "cited",
      "cases": 200,
      "disagree": 0,
      "instructionsRetired": 929
    },
    {
      "test": "stm8_streams_agree_with_the_reference",
      "profile": "stm8",
      "basis": "default",
      "cases": 2000,
      "disagree": 8,
      "instructionsRetired": 9324
    }
  ],
  "defaultCountFailure": {
    "cases": 2000,
    "seed": 20261120,
    "disagreements": 8,
    "disagreementClasses": {
      "CC": 8
    },
    "failingCases": [
      222,
      235,
      546,
      1097,
      1158,
      1388,
      1500,
      1640
    ],
    "what": "In every listed case the program ends with DIV or DIVW and only the Z bit of the condition-code register differs.",
    "cause": "A defect of the reference. ucsim 0.6.4 sets Z after DIV and DIVW when the quotient is not zero (inst.cc lines 978 and 980); the STM8 programming manual PM0044 (Rev 3, pages 101 and 102) says Z is set when the quotient is zero, which the core implements. ucsim 0.8.15 agrees with the core and with PM0044. 336 of 336 divisions measured on the reference image have Z inverted in ucsim 0.6.4.",
    "firstCaseAt200": 222,
    "note": "The 200-case run passes only because the first disagreeing case is number 222.",
    "fix": "A change to the reference profile (a TNZ A after every DIV and DIVW) is on a development branch and is not part of this record."
  },
  "referenceDeviations": 0,
  "notCovered": [
    "interrupt entry, IRET, TRAP, INT, WFI, WFE, HALT and BREAK (the reference is driven without its interrupt controller)",
    "JPF, CALLF and RETF and the extended (24-bit) LDF forms beyond the 64 KiB window (the reference models a 16-bit address space here)",
    "the cycle counts (the reference exposes none)",
    "division by zero (the manual leaves DIVW undefined)",
    "JRIL, JRIH, JRM and JRNM (they read interrupt state outside the core)",
    "the stack limit and wrap-around of a part (the reference's limit is that of its default part)"
  ],
  "negativeControls": [
    {
      "id": "stm8-xor-or",
      "change": "XOR is computed as OR",
      "casesPerProfile": 2000,
      "profiles": 1,
      "casesRejecting": 49,
      "casesRejectingAttributableToTheDefect": 41
    }
  ]
}
