Politehica din Bucuresti proiect de diplomă Facultatea transporturi


Syntax: Operands: Program Counter



Yüklə 1,46 Mb.
səhifə96/104
tarix09.01.2022
ölçüsü1,46 Mb.
#91958
1   ...   92   93   94   95   96   97   98   99   ...   104
Syntax: Operands: Program Counter:

(i) BREQ k -64  k  +63 PC  PC + k + 1

PC  PC + 1, if condition is false



16-bit Opcode:


1111

00kk

kkkk

k001

Status Register (SREG) and Boolean Formulae:


I T H S V N Z C

-

-

-

-

-

-

-

-


Exemplu:

cp r1,r0 ; Compare registers r1 and r0

breq equal ; Branch if registers equal

equal: nop ; Branch destination (do nothing)



BRNE - Branch if Not Equal
Descriere:

Salt condiţionat relativ. Testează indicatorul “Z”; dacă acesta e “0” logic, PC creşte cu k+1 altfel creşte normal cu 1. Indicatorul Z este 0 dacă Rd ≠ Rr , în registre fiind numere cu sau fară semn. Saltul se face cu +k sau –k. Parametru k este un deplasament faţă de valoarea din PC şi este reprezentat în complement faţă de 2.


Operation:

(i) If Rd  Rr (Z = 0) then PC  PC + k + 1, else PC  PC + 1



Yüklə 1,46 Mb.

Dostları ilə paylaş:
1   ...   92   93   94   95   96   97   98   99   ...   104




Verilənlər bazası müəlliflik hüququ ilə müdafiə olunur ©muhaz.org 2024
rəhbərliyinə müraciət

gir | qeydiyyatdan keç
    Ana səhifə


yükləyin