• Aucun résultat trouvé

CPU (3)

N/A
N/A
Protected

Academic year: 2022

Partager "CPU (3)"

Copied!
64
0
0

Texte intégral

(1)

TD7

CPU (3)

(2)

Implémentation de la

machine à états finis

(3)
(4)

découpage de chaque instructions en une série de pas

un pas est exécuté à chaque top de l'horloge

un pas peut être constitué de plusieurs opérations exécutées en parallèle

à l’intérieur d’un pas, certaines opérations pourront se révéler inutiles, mais cela n’aura pas rallongé le temps d’exécution

en général

aller chercher l'instruction

décoder l'instruction

exécuter l'instruction

terminer l'exécution de l'instruction

implémentation multicycle

(5)

implémentation multicycle

(6)
(7)

implémentation multicycle

(8)
(9)

implémentation multicycle

(10)

implémentation multicycle

(11)

implémentation multicycle

(12)

implémentation multicycle

(13)

implémentation multicycle

(14)

implémentation multicycle

(15)

implémentation multicycle

(16)

implémentation multicycle

(17)

5 2 8

3

4

MemRead ALUSrcA = 0

IorD= 0 IRWrite ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0

MemWrite IorD = 1 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

7

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

exécution

PCWrite PCSource=10

exécution 9

4 bits pour décrire les 10 états des machines : S3 S2

S1 S0

ALUSrcA = 0 ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

[S3,S2,S1,S0] = [1000]

S3. S2 . S1 . S0

chargement

[S3,S2,S1,S0] = [0110]

S3 . S2 . S1 . S0

(18)

les entrées de la logique de contrôle sont :

les 6 bits de poids fort de l'instruction Op5 Op4 Op3 Op2 Op1 Op0

l'état courant de la machine décrit par les 4 bits

S3 S2 S1 S0

les sorties sont :

les lignes de contrôle

l'état suivant de la machine décrit par les 4 bits

NS3 NS2 NS1 NS0

écrit dans le registre d'état et validé comme état courant au tick d'horloge suivant

State n

NextState n

(19)
(20)

2 parties dans la logique combinatoire du bloc de contrôle :

les lignes de contrôle du chemin de données

l'état suivant de la machine à états finis

(21)

Sorties État courant Op PCWrite

PCWriteCond IorD

MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NextState0 NextState1 NextState2 NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(22)

5 2 8

3

4

MemRead ALUSrcA = 0

IorD= 0 IRWrite ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0

MemWrite IorD = 1 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

7

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

exécution

PCWrite PCSource=10

exécution 9

ALUSrcA = 0 ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

l'activation des lignes de commandes est le OU des états pour lesquels elles sont à 1

chargement

(23)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond IorD

MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NextState0 NextState1 NextState2 NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(24)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond state8

IorD state3 + state5 MemRead state0 + state3 MemWrite state5

IRWrite state0 MemtoReg state4 PCSource1 state9 PCSource0 state8 ALUOp1 state6 ALUOp0 state8

ALUSrcB1 state1 + state2 ALUSrcB0 state0 + state1

ALUSrcA state2 + state6 + state8 RegWrite state4 + state7

RegDest state7 NextState0

NextState1 NextState2 NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(25)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(26)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(27)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(28)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond state8

IorD state3 + state5

MemRead state0 + state3 MemWrite state5

IRWrite state0

MemtoReg state4 PCSource1 state9 PCSource0 state8

ALUOp1 state6

ALUOp0 state8

ALUSrcB1 state1 + state2 ALUSrcB0 state0 + state1

ALUSrcA state2 + state6 + state8 RegWrite state4 + state7

RegDest state7

NextState0 state4 + state5 + state7 + state8 + state9 NextState1

NextState2 NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(29)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(30)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' ) (O

p = 'BE Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(31)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond state8

IorD state3 + state5

MemRead state0 + state3 MemWrite state5

IRWrite state0

MemtoReg state4 PCSource1 state9 PCSource0 state8

ALUOp1 state6

ALUOp0 state8

ALUSrcB1 state1 + state2 ALUSrcB0 state0 + state1

ALUSrcA state2 + state6 + state8 RegWrite state4 + state7

RegDest state7

NextState0 state4 + state5 + state7 + state8 + state9 NextState1 state0

NextState2 NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(32)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' )

(Op = 'BE

Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(33)

7

exécution 9 8

4

5 2

3

MemRead ALUSrcA = 0

IorD= 0 ALUSrcB = 01

ALUOp= 00 PCWrite PCSource = 00

(Op = 'LW' ou Op = 'SW' )

(Op = 'BE

Q') 0

ALUSrcA = 1 ALUSrcB = 10

ALUOp = 00

MemRead IorD = 1

RegWrite MemtoReg = 1

RegDst = 0 (Op='LW')

(Op='SW') calcul de

l'adresse mémoire

accès mémoire

fin de la lecture mémoire

accès mémoire

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 10

RegDst = 1 RegWrite MemtoReg = 0

exécution

fin de l'opération 6

ALUSrcA = 1 ALUSrcB = 00

ALUOp = 01 PCWriteCond PCSource=01

PCWrite PCSource=10

exécution ALUSrcA = 0

ALUSrcB =11 ALUOp = 00

(Op = type R) (O

p = 'J') 1

décodage

Les états suivants NextStaten sont les OU des prédécesseurs

chargement

MemWrite IorD = 1

(34)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond state8

IorD state3 + state5

MemRead state0 + state3 MemWrite state5

IRWrite state0

MemtoReg state4 PCSource1 state9 PCSource0 state8

ALUOp1 state6

ALUOp0 state8

ALUSrcB1 state1 + state2 ALUSrcB0 state0 + state1

ALUSrcA state2 + state6 + state8 RegWrite state4 + state7

RegDest state7

NextState0 state4 + state5 + state7 + state8 + state9 NextState1 state0

NextState2 state1 (Op='lw') + (Op='sw')

NextState3 NextState4 NextState5 NextState6 NextState7 NextState8 NextState9

(35)

Sorties État courant Op PCWrite state0 + state9

PCWriteCond state8

IorD state3 + state5

MemRead state0 + state3 MemWrite state5

IRWrite state0

MemtoReg state4 PCSource1 state9 PCSource0 state8

ALUOp1 state6

ALUOp0 state8

ALUSrcB1 state1 + state2 ALUSrcB0 state0 + state1

ALUSrcA state2 + state6 + state8 RegWrite state4 + state7

RegDest state7

NextState0 state4 + state5 + state7 + state8 + state9 NextState1 state0

NextState2 state1 (Op='lw') + (Op='sw')

NextState3 state2 (Op='lw')

NextState4 state3

NextState5 state2 (Op='sw')

NextState6 state1 (Op='R-type')

NextState7 state6

NextState8 state1 (Op='beq')

NextState9 state1 (Op='jmp')

(36)

chaque futur état NextStatex est le OR des états courants Statex qui peuvent y conduire.

si il y a une condition sur l'Opcode de l'instruction qui y conduit, on fait un AND avec ces conditions

etc...

NextState1 = State0 = S3 . S2 . S1 . S0

NextState3 = State2.  Op [ 5 − 0 ] = lw 

= S3 .S2 . S1 .S0 . Op5 .Op4. Op3.Op2 .Op1 .Op0 NextState2 = State1. { Op [ 5 − 0 ] = lw  Op [ 5 − 0 ] = sw }

= S3 .S2 . S1 .S0 .

 Op5 .Op4 .Op3. Op2.Op1 .Op0  Op5 .Op4 .Op3 .Op2.Op1 .Op0 

= S3 .S2 . S1 .S0 . Op5 .Op4. Op2.Op1 .Op0

(37)

Les états NextStatex sont rprésentés par le codage binaire de x avec NS3, NS2 , NS1 et NS0

NS3 NS2 NS1 NS0

NextState0 0 0 0 0

NextState1 0 0 0 1

NextState2 0 0 1 0

NextState3 0 0 1 1

NextState4 0 1 0 0

NextState5 0 1 0 1

NextState6 0 1 1 0

NextState7 0 1 1 1

NextState8 1 0 0 0

NextState9 1 0 0 1

(38)

NS0 sera actif (VRAI) à chaque fois que l'état suivant NexState x aura NS0=1dans son encodage

c'est le cas de NextState1, NextState3, NextState5, NextState7 et NextState9

NS0 = NextState1+NextState3+NextState5+

NextState7+NextState9

NS0 = S3.S2.S1.S0

 S3.S2.S1.S0. Op5 .Op4 .Op3.Op2.Op1.Op0

 S3.S2.S1.S0.Op5.Op4 .Op3.Op2.Op1 .Op0

 S3.S2.S1.S0

 S3.S2.S1.S0.Op5.Op4.Op3.Op2.Op1.Op0

(39)

de même

NS1 = NextState2 + NextState3 + NextState6 + NextState7

NS2 = NextState4 + NextState5 + NextState6 + NextState7

NS3 = NextState8 + NextState9

(40)

S3 S2 S1 S0

0 0 0 0

1 0 0 1

PCWrite

S3 S2 S1 S0

1 0 0 0

PCWritCond

S3 S2 S1 S0

0 0 1 1

0 1 0 1

IorD

S3 S2 S1 S0

0 0 0 0

0 0 1 1

MemRead

S3 S2 S1 S0

0 1 0 1

MemWrite

S3 S2 S1 S0

0 0 0 0

IRWrite

S3 S2 S1 S0

0 1 0 0

MemtoReg

S3 S2 S1 S0

1 0 0 1

PCSource1

S3 S2 S1 S0

1 0 0 0

PCSource0

S3 S2 S1 S0

0 1 10

ALUOp1

S3 S2 S1 S0

1 0 0 0

ALUOp0

S3 S2 S1 S0

0 0 0 1

0 0 1 0

ALUSrcB1

S3 S2 S1 S0

0 1 1 1

RegDest

S3 S2 S1 S0

0 0 0 0

0 0 0 1

ALUSrcB0

S3 S2 S1 S0

0 0 1 0

0 1 1 0

1 0 0 0

ALUSrcA

S3 S2 S1 S0

0 1 0 0

0 1 1 1

RegWrite

(41)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

0 0 0 0 1 0 0 0 0 1

0 0 0 1 0 0 0 0 0 1

NS3

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

0 0 0 0 0 0 0 0 0 1

1 0 1 0 1 1 0 0 1 0

X X X X X X 0 0 1 1

X X X X X X 0 1 1 0

NS2

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

0 0 0 0 0 0 0 0 0 1

1 0 X 0 1 1 0 0 0 1

1 0 0 0 1 1 0 0 1 0

X X X X X X 0 1 1 0

NS1

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

X X X X X X 0 0 0 0

1 0 0 0 1 1 0 0 1 0

1 0 1 0 1 1 0 0 1 0

X X X X X X 0 1 1 0

0 0 0 0 1 0 0 0 0 1

NS0

(42)

Implémentation avec un PLA

qu'est ce qu'un PLA ?

combinaison de portes ET et OU permettant de réaliser de façon programmable des somme canoniques de produits

caractérisés par

le nombre d'entrées n

le nombre de sorties m

le nombre de minterms p

(43)

Implémentation avec un PLA

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

10 entrées

20 sorties

PCWrite

PCWriteCond

IorD MemRead

MemWrite

IRWrite

MemtoReg

PCSource1

PCSource0

ALUOp1

ALUOp0

ALUSrcB1

ALUSrcB0

ALUSrcA

RegWrite

RegDest

NS3 NS2

NS1 NS0

(44)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

Minterms des "Staten"

(45)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0

(46)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0

porte ET

(47)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

(48)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9

(49)

NS0 Op5

Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9

Minterms des "NextStatesn"

dépendants des codes opératoires

(50)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9

nextState 9 = (Op = J).state 1

= Op 5. Op 4.Op 4 .Op 3 .Op 2 .Op 1 .Op0.S 3. S2 .S 1.S 0

(51)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9

nextState 9 = (Op = J).state 1

= Op 5. Op 4.Op 4 .Op 3 .Op 2 .Op 1 .Op0.S 3. S2 .S 1.S 0

(52)

Op5 Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

(53)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0 Op5

Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

réalisation des lignes de contrôle

(54)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0 Op5

Op4 Op3 Op2 Op1 Op0 S3 S2 S1 S0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

réalisation des lignes de contrôle

PCWrite = state0 + state9

(55)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

réalisation des lignes de contrôle

PCWrite = state0 + state9

porte

OU

(56)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

porte

OU

(57)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

porte OU

réalisation des lignes NSn

(58)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

porte OU

réalisation des lignes NSn

NS3 = nextState8 + nextState9

(59)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

porte OU

réalisation des lignes NSn

NS3 = nextState8 + nextState9

(60)

PCWrite PCWriteCond IorD MemRead MemWrite IRWrite MemtoReg PCSource1 PCSource0 ALUOp1 ALUOp0 ALUSrcB1 ALUSrcB0 ALUSrcA RegWrite RegDest NS3 NS2 NS1 NS0

state0 state1

porte ET

state2 state3 state4 state5 state6 state7 state8 state9 nextState9 nextState8 nextState6 nextState5 nextState3 nextState2

porte OU

réalisation des lignes NSn

(61)

taille des mots ?

16 lignes de commandes + 4 bits pour l'état suivant

20 bits

taille de la mémoire ?

10 bits : Op[5-0 ] S[3-0]

2 10 mots = 1024 mots

20 Kbits

Implémentation dans une ROM

(62)

Implémentation dans une ROM

adresse :

A9 A8 A7 A6 A5 A4 A3 A2 A1 A0

D19 D18 D17 D16 D15 D14 D13 D12 D11 D10 D9 D8 D7 D6 D5 D4 D3 D2 D1 D0

dans quels mots le bit D19 sera vrai ?

PCWrite vrai pour State0 et State9

XXXXXX0000 et XXXXXX1001

0000000000

0000001001

0000010000

0000011001

etc...

(63)

Implémentation dans une ROM

comment le réaliser avec des blocs mémoires de 256 octets ?

bloc mémoire de 1024 octets

8

A0 A8 A0 A8 A0 A8 A0 A8

CE CE CE CE

S0 S1 S2 S3 Op0 Op1 Op2 Op3

Op5 Op4

0 1

2 3

(64)

Implémentation dans une ROM

3 blocs de 1024 octets

S0 S1 S2 S3 Op0 Op1 Op2 Op3 Op4 Op5

PCWrite PCWriteCond

NS0 NS1

NS2 NS3

RegDest

Références

Documents relatifs

RegDest ALUSrc MemtoReg RegWrite MemRead MemWrite Branch ALUOp1 ALUOp0

As explained in the previous section, the Memory Manager's port address decoder is shared with the processor swap port.. This completes the description of the

If the product is delivered by mail or common carrier, you agree to insure the product or assume the risk of loss or damage in transit, to prepay shipping charges

A full 32 bit DMA Controller supporting data trans- fers to/from VMEbus memory as well as to/from local system RAM is provided by a FORCE specific 280 pin Gate

Control bits in the Memory Management Unit (MMU), the CCR and a CPU register allow the cache to be disabled completely, bypassed on data reads only, or bypassed selectively

show bgp neighbor z.z.z.z routes debug bgp update z.z.z.z in <rpl>. Calculate Partial best-paths

border 10.1.1.2 key-chain key1 interface Ethernet8/0 internal interface Serial12/0 external interface Serial13/0 external border 10.1.1.3 key-chain key1. interface Ethernet

exit Exit from OER master controller configuration submode holddown Specify hold-down timer parameter. keepalive Specify