Z80

For technical information on the Z80, three very good resources are:


 * Thomas Scherrer's z80.info: official Zilog manuals and the like
 * Sean Young's The Undocumented Z80 Documented: undocumented features
 * memptr_eng.txt: the undocumented flags after BIT n,(HL)

Additional information
Mark Woodmass has confirmed that bits 3 and 5 of the flags are copied on all BIT instructions on both a Zilog Z80 and an NEC clone (stated on the link above as being "unverified").

Stuart Brady has discovered that how bits 3 and 5 of the flags are set after the SCF and CCF instructions actually depends on the variant of Z80 in use. On a Zilog Z80, bits 3 and 5 of the flags were set by ORing their previous values with that of A. On an NEC clone, bit 3 was unaffected, while bit 5 appears to be set by ANDing the previous value with something unknown. Previously, Ian Greenway has tested this and discovered that bits 3 and 5 were simply copied from A, although it is not known which CPU these tests were run on. For more details, see here and here. Any further information on this is welcomed.