cmpw.cgs 261 B

1234567891011121314151617181920212223
  1. # cr16 testcase for cmp $imm, reg
  2. # mach(): cr16
  3. .include "testutils.inc"
  4. start
  5. .global cmp
  6. cmp:
  7. mvi_h_condbit 0
  8. movw $0x1234, r4
  9. movw $0x1234, r5
  10. cmpb r4,r5
  11. beq ok
  12. not_ok:
  13. fail
  14. ok:
  15. mvi_h_condbit 1
  16. movw $0x2222, r5
  17. cmpw r4,r5
  18. beq not_ok
  19. pass