m68k 汇编的 IF-THEN-ELSE

; IF d0 == 10 GO TO ten, ELSE GO TO other
    CMP    #10,d0        ; compare register contents to immediate value 10
                         ; instruction affects the zero flag
    BEQ    ten           ; branch if zero flag set
other:
    ; do whatever needs to be done for d0 != 10
    BRA    afterother    ; unconditionally jump across IF case 
ten:
    ; do whatever needs to be done for d0 == 10
afterother:
    ; continue normal common program flow

哪些指令影响哪些标志,哪些条件分支(也可能基于特定的标志组合 )可用,很大程度上取决于你选择的 CPU,应在手册中查找。