csa2.s 412 B

123456789101112131415161718192021222324252627
  1. .sect .text; .sect .rom; .sect .data; .sect .bss
  2. .define .csa2
  3. .sect .text
  4. .csa2:
  5. ! bx, descriptor address
  6. ! ax, index
  7. mov dx,(bx) ! default
  8. sub ax,2(bx)
  9. cmp ax,4(bx)
  10. ja 1f
  11. sal ax,1
  12. add bx,ax
  13. mov bx,6(bx)
  14. test bx,bx
  15. jnz 2f
  16. 1:
  17. mov bx,dx
  18. test bx,bx
  19. jnz 2f
  20. .extern ECASE
  21. .extern .fat
  22. mov ax,ECASE
  23. push ax
  24. jmp .fat
  25. 2:
  26. jmp bx