










Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!











Computer Instructions Encoding
Variable length Encoding .. Cont’d
Operation and number of operands Address Specifier # 1 Address Specifier #n Address Field # n Address field # 1
Operation code Address field # 1 Address field # 3 Address field # 2
op code destination source 1 source 2 next address op code destination source 1 source 2
Hybrid Length Taxonomy .. Cont’d 2-address instructions
op code destination source 1 source 2 op code source 2
Example Evaluate the expression: F = (B + C)*D – E using 0- address through 3-address format
Number of
Another example:
ADD x, A, B MUL y, x, 4 ADD r, C, 58 MUL s, r, 16 SUB Z, y, s LOAD y, B MUL y, 4 LOAD s, C ADD s, 58 MUL s, 16 SUB y, s STORE Z, y ; order changed to reduce code size LDA C ADDA 58 MULA 16 STA S LDA A ADDA B MULA 4 SUBA s STA Z
op code destination source 1 source 2 next address 1 byte 3 bytes 3 bytes 3 bytes 3 bytes
1 byte 3 bytes 3 bytes 3 bytes op code destination source 1 source 2