?login_element?

Subversion Repositories NedoOS

Rev

Blame | Last modification | View Log | Download

  1.     OUTPUT "op_BIT_CB.bin"      ; all of these should pass except "sli" (= swap)
  2.  
  3.     ;;; generate shift instructions: #CB00 .. #CB3F
  4.     DEFARRAY instructions rlc, rrc, rl, rr, sla, sra, sli, srl
  5.     DEFARRAY registers b, c, d, e, h, l, (hl), a
  6.  
  7. INS_I=0
  8.     DUP 8
  9. REG_I=0
  10.         DUP 8
  11.             instructions[INS_I] registers[REG_I]
  12. REG_I=REG_I+1
  13.         EDUP
  14. INS_I=INS_I+1
  15.     EDUP
  16.  
  17.     ;;; generate bit-manipulation instructions: #CB40 .. #CBFF
  18.     DEFARRAY instructions2 bit, res, set
  19. INS_I=0
  20.     DUP 3
  21. REG_BIT=0
  22.         DUP 8
  23. REG_I=0
  24.             DUP 8
  25.                 instructions2[INS_I] REG_BIT,registers[REG_I]
  26. REG_I=REG_I+1
  27.             EDUP
  28. REG_BIT=REG_BIT+1
  29.         EDUP
  30. INS_I=INS_I+1
  31.     EDUP