Changeset 55


Ignore:
Timestamp:
Sep 10, 2010, 12:28:59 PM (8 years ago)
Author:
mulligan
Message:

CJNE instruction finished.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Deliverables/D4.1/ASMInterpret.ml

    r54 r55  
    880880 | JZ of rel
    881881 | JNZ of rel
     882*)
     883 | CJNE ((`U1 (`A, ag)), `REL rel) ->
     884     let ag_val = fetch_arg8 status ag in
     885     let acc_val = status.acc in
     886     let new_carry = acc_val < ag_val in
     887       if ag_val <> acc_val then
     888         { status with pc = status.pc ++ (int_of_byte rel) }
     889       else
     890         status
     891 | CJNE ((`U2 (ag, `DATA d)), `REL rel) ->
     892     let ag_val = fetch_arg8 status ag in
     893     let new_carry = ag_val < d in
     894       if ag_val <> d then
     895         { status with pc = status.pc ++ (int_of_byte rel) }
     896       else
     897         status
     898(*
    882899 | CJNE of (acc * [ direct | data ], [ reg | indirect ] * data) union2 * rel
    883900 | DJNZ of [ reg | direct ] * rel
Note: See TracChangeset for help on using the changeset viewer.