Professional Documents
Culture Documents
Lw $t0,big($s2):
lui $t1, upper(big)
ori $t1, $t1, lower(big)
add $t1, $t1, $t2
lw $t5, 0($t1)
bge $s0,$s1,Label
slt $at, $t5, $t3
beq $at, $zero, L
beqz $t1,Label
beq $t1,$0,L
seq $s0,$s1,$s2 // Cu ni mo hiu lm, nn ko chc
beq $at,$s1,$s2
beq $at,$0,L
or $s0,$s0,$0
j Exit
L: nor $s0,$0,$02.
Exit:
2.
Tng s cycles lnh ca chng trnh:
300.10^6.5 +300.4.10^6 + 500.10^6.4+100.10^6.3 = 5.10^9 cycles
=>Execution time = clock cycle/ clock rate = 5.10^9/1,25.10^9 = 4s
3.
001010 10000 10001 0000000000000110
000000 00000 10010 10011 00100 000011
000001 00000 00001 1111111111111111
4.
000110 01000 00000 0000000000000001
101011 01111 11000 0000000000000000
100011 01000 00100 0000000000000100