APPLICATIONSDIVERS ★ ZEXDOC: Z80 DOCUMENTED INSTRUCTION SET EXERCISER ★

Zexdoc: Z80 documented instruction set exerciserApplications Divers
★ Ce texte vous est présenté dans sa version originale ★ 
 ★ This text is presented to you in its original version ★ 
 ★ Este texto se presenta en su versión original ★ 
 ★ Dieser Text wird in seiner Originalfassung präsentiert ★ 

For the purposes of this test program, the machine state consists of:

  • a 2 byte memory operand, followed by the registers iy,ix,hl,de,bc,af,sp
for a total of 16 bytes.

The program tests instructions (or groups of similar instructions) by cycling through a sequence of machine states, executing the test instruction for each one and running a 32-bit crc over the resulting machine states. At the end of the sequence the crc is compared to an expected value that was found empirically on a real Z80.

A test case is defined by a descriptor which consists of:

  • a flag mask byte,
  • the base case,
  • the incement vector,
  • the shift vector,
  • the expected crc,
  • a short descriptive message.

The flag mask byte is used to prevent undefined flag bits from influencing the results. Documented flags are as per Mostek Z80 Technical Manual.

The next three parts of the descriptor are 20 byte vectors corresponding to a 4 byte instruction and a 16 byte machine state. The first part is the base case, which is the first test case of the sequence. This base is then modified according to the next 2 vectors. Each 1 bit in the increment vector specifies a bit to be cycled in the form of a binary counter. For instance, if the byte corresponding to the accumulator is set to 0ffh in the increment
vector, the test will be repeated for all 256 values of the accumulator. Note that 1 bits don't have to be contiguous. The number of test cases 'caused' by the increment vector is equal to 2^(number of 1 bits). The shift vector is similar, but specifies a set of bits in the test case that are to be successively inverted. Thus the shift vector 'causes' a number of test cases equal to the number of 1 bits in it.

The total number of test cases is the product of those caused by the counter and shift vectors and can easily become unweildy. Each individual test case can take a few milliseconds to execute, due to the overhead of test setup and crc calculation, so test design is a compromise between coverage and execution time.

This program is designed to detect differences between implementations and is not ideal for diagnosing the causes of any discrepancies. However, provided a reference implementation (or real system) is available, a failing test case can be isolated by hand using a binary search of the test space.

https://CPCrulez.fr

★ YEARS: 1994 , 2002
★ CONFIG: 128K + CP/M 2.2
★ LANGUAGE:
★ LiCENCE: FREEWARE
★ AUTHORS: Frank D. Cringle , J.G.Harston

★ AMSTRAD CPC ★ DOWNLOAD ★

File:
» ZexdocDATE: 2014-07-01
DL: 249
TYPE: ZIP
SiZE: 44Ko
NOTE: CPM 2.2 bootloader/Extended DSK/40 Cyls
.HFE: Χ

★ AMSTRAD CPC ★ A voir aussi sur CPCrulez , les sujets suivants pourront vous intéresser...

Lien(s):
» Applications » Camsoft Stock Control
» Applications » Condor 1 (Amstrad Action)
» Applications » Introduction à G.S.X (CPC Revue n°33)
» Applications » CP/M Plus mit 64 Hz (CPC Amstrad International)
» Applications » Dams et CP/M (CPC Revue)
» Applications » CAT-Befehl für CP/M (CPC Amstrad International)
Je participe au site:
» Vous avez des infos personnel ?
» Vous avez remarqué une erreur dans ce texte ?
» Aidez-nous à améliorer cette page : en nous contactant via le forum ou par email.

CPCrulez[Content Management System] v8.7-desktop/c
Page créée en 387 millisecondes et consultée 1721 fois

L'Amstrad CPC est une machine 8 bits à base d'un Z80 à 4MHz. Le premier de la gamme fut le CPC 464 en 1984, équipé d'un lecteur de cassettes intégré il se plaçait en concurrent  du Commodore C64 beaucoup plus compliqué à utiliser et plus cher. Ce fut un réel succès et sorti cette même années le CPC 664 équipé d'un lecteur de disquettes trois pouces intégré. Sa vie fut de courte durée puisqu'en 1985 il fut remplacé par le CPC 6128 qui était plus compact, plus soigné et surtout qui avait 128Ko de RAM au lieu de 64Ko.