Chapter Five The Processor: Datapath and Control (Parte B: multiciclo)

Slides:



Advertisements
Apresentações semelhantes
Presenter’s Notes Some Background on the Barber Paradox
Advertisements

Chapter Six Pipelining
Chapter Four Arithmetic for Computers
1998 Morgan Kaufmann Publishers Mario Côrtes - MO401 - IC/Unicamp- 2004s2 Ch5A-1 Chapter Five The Processor: Datapath and Control.
MC542 Organização de Computadores Teoria e Prática
Conjunto de Instruções MIPS
PIPELINE (continuação).
Exemplo de arquitetura registrador-registrador- MIPS
MIPS MULTICICLO Fluxo de Dados e Controle
Processador Fluxo de Dados e Controle
AULA 06 - MIPS PIPELINE.
Tolerância a falha é a habilidade de um sistema de continuar a realizar corretamente as suas tarefas depois da ocorrência de falhas. 3. Introduction to.
Conversation lesson Unit 14 – Poetry/ Song Teacher: Anderson.
MC542 Organização de Computadores Teoria e Prática
MO401 Arquitetura de Computadores I
MC613 Laboratório de Circuitos Lógicos
MC Prof. Paulo Cesar Centoducatte MC542 Organização de Computadores Teoria e Prática.
Chapter 3 Instructions: Language of the Machine
MC542 Organização de Computadores Teoria e Prática
1998 Morgan Kaufmann Publishers Paulo C. Centoducatte - IC/Unicamp- 2002s Prof. Paulo Cesar Centoducatte
1998 Morgan Kaufmann Publishers Mario Côrtes - MO401 - IC/Unicamp- 2002s1 Ch6-1 Chapter Six Pipelining.
1998 Morgan Kaufmann Publishers Mario Côrtes - MO401 - IC/Unicamp- 2004s2 Ch7a-1 Chapter Seven Sistemas de Memória.
MO Prof. Paulo Cesar Centoducatte MC542 Organização de Computadores Teoria e Prática.
1998 Morgan Kaufmann Publishers Mario Côrtes - MO401 - IC/Unicamp- 2002s1 Ch7-1 Chapter Seven Sistemas de Memória.
MC Prof. Paulo Cesar Centoducatte MC542 Organização de Computadores Teoria e Prática.
DIRETORIA ACADÊMICA NÚCLEO DE CIÊNCIAS HUMANAS E ENGENHARIAS DISCIPLINA: INGLÊS FUNDAMENTAL - NOITE PROFESSOR: JOSÉ GERMANO DOS SANTOS PERÍODO LETIVO
DIRETORIA ACADÊMICA NÚCLEO DE CIÊNCIAS HUMANAS E ENGENHARIAS DISCIPLINA: INGLÊS FUNDAMENTAL - NOITE PROFESSOR: JOSÉ GERMANO DOS SANTOS PERÍODO LETIVO
Fundamentos da teoria dos semicondutores Faixas de energia no cristal semicondutor. Estatística de portadores em equilíbrio. Transporte de portadores.
A Arquitetura: conjunto de instruções
1998 Morgan Kaufmann Publishers Ch5B-1 O Processador: Via de Dados e Controle (Parte C: microprogramação)
GT Processo Eletrônico SG Documentos Eletrônicos Segunda reunião – 28/08/2009 Interlegis.
Capítulo I – Conceitos Primários 1.1 – Estrutura de um computador 1.2 – Informações manipuladas por um computador 1.3 – Evolução das linguagens de programação.
O DSP possui 4 timers de 16 bits: –São independentes; –São utilizados para gerar uma base de tempo utilizada para os programas (temporizações em geral);
Protocolo HTTP.
FLUP - Elena Zagar Galvão Faculdade de Letras da Universidade do Porto Mestrado em Tradução e Serviços Linguísticos COMUNICAÇÃO ESPECIALIZADA INTRODUÇÃO.
Organização ou MicroArquitectura
Acção de Formação A Biblioteca Escolar: Leitura e Literacia no 2º e 3º ciclos do Ensino Básico e Secundário Centro de Formação Júlio Brandão
Indirect Object Pronouns - Pronomes Pessoais Complemento Indirecto
Tópicos Especiais em Aprendizagem Reinaldo Bianchi Centro Universitário da FEI 2012.
Números de 0 a 1,000,000,000 É uma dúvida de muitos estudantes do nível básico como dizer os números em inglês. Segue abaixo a lista de 0 a 1,000,000,000.
Fazendo e Brincando: Confecção de Materiais para as Aulas de Inglês
INPE / CAP-315 Airam J. Preto, Celso L. Mendes Aula 30 (1) Empacotamento de Dados em MPI Tópicos: Buffer de Mensagem Empacotamento/Desempacotamento.
Universidade de Brasília Laboratório de Processamento de Sinais em Arranjos 1 Adaptive & Array Signal Processing AASP Prof. Dr.-Ing. João Paulo C. Lustosa.
Knowledge Extraction from the Web (ISEWO)
Lecture 4 Pressure distribution in fluids. Pressure and pressure gradient. Hydrostatic pressure 1.
ORGANIZAÇÃO E ARQUITETURA DE COMPUTADORES I prof. Dr. César Augusto M. Marcon prof. Dr. Edson Ifarraguirre Moreno Memórias.
Infra-estrutura de Hardware
Balanço de Forças e de Quantidade de Movimento
Aula Teórica 12 Equação de Bernoulli. Bernoulli’s Equation Let us consider a Stream - pipe such as indicated in the figure and an ideal fluid (without.
RELATÓRIO CEMEC 06 COMPARAÇÕES INTERNACIONAIS Novembro 2013.
Microprocessadores 8051 – Aula 3 Interrupção
Equação de Bernoulli e Equação de Conservação da Energia
IEEE PES General Meeting, Tampa FL June 24-28, 2007 Conferência Brasileira de Qualidade de Energia Santos, São Paulo, Agosto 5-8, Chapter 8: Procedure.
Administração e Exploração Avançada de Bases de Dados Mestrado em Engenharia de Sistemas Braga, 2014.
Parte 3 Seção de Dados e Unidade de Controle
1  1998 Morgan Kaufmann Publishers Paulo C. Centoducatte – MC542 - IC/Unicamp- 2006s Prof. Paulo Cesar Centoducatte
Estrutura do Processador
Redes Sociais Online ISCTE – Instituto Universitário de Lisboa MCCTI Mónica Oliveira 13 de Março de 2013.
Communicate - Trade - Culture William Barron Mobile/Cell –
Verilog HDL. Introduzida em 1985 pela Gateway Design System Corporation Após 1990, passou a ser de domínio público, e em 1995 passou a ser padrão IEEE.
Adriano Melo IDE Eclipse + Subclipse Link para download: \\cin01\scratch_astm$\eclipse.zip
Pesquisa Operacional aplicada à Gestão de Produção e Logística Prof. Eng. Junior Buzatto Case 3.
Subway Network - São Paulo City
Funcionamento básico de um processador de 8 bits
Determinou o endereço de A
Tópicos Avançados em Engenharia de Software
Chapter Six Pipelining Harzard
Pesquisadores envolvidos Recomenda-se Arial 20 ou Times New Roman 21.
shut up! Go on! Multi-word verbs Hold on, please! Look out!
Chapter 3 Instructions: Language of the Machine
Transcrição da apresentação:

Chapter Five The Processor: Datapath and Control (Parte B: multiciclo)

Multicycle Approach Break up the instructions into steps, each step takes a cycle balance the amount of work to be done restrict each cycle to use only one major functional unit 1 ALU, 1 Memória, 1 Banco de Registradores At the end of a cycle store values for use in later cycles (easiest thing to do) introduce additional “internal” registers P C M e m o r y A d s I n t u c i a D g R # L U B O

Multicycle Approach IR (Instruction Register) e MDR (Memory Data Register) salvam saída da memória Registradores A e B salvam saída do banco de registradores ALUout salva saída da ALU Todos, exceto IR, guardam dados por um clock Þ controle de escrita é desnecessário novos MUXes: endereço da memória, operandos da ALU S h i f t l e 2 P C M m o r y D a W d u x 1 R g s 4 I n c [ 5 – ] 3 6 A L U Z B O

Via de dados multiciclo e sinais de controle h i f t l e 2 M m o R g I r D a d W P C y u x 1 s n c [ 5 – ] 4 A L U O p B 3 6 Z Falta implementar 3 possíveis fontes de carga para PC: PC+4, beq e j

Via de dados completa S h i f t l e 2 P C M u x 1 R g s r W d a I n c 1 R g s r W d a I n c o [ 5 – ] 4 3 6 A L U Z m y B D O p - J 8

Sinais de controle (1 bit)

Sinais de controle (2 bits)

Five Execution Steps Instruction Fetch Instruction Decode and Register Fetch Execution, Memory Address Computation, or Branch Completion Memory Access or R-type instruction completion Write-back step INSTRUCTIONS TAKE FROM 3 - 5 CYCLES!

Step 1: Instruction Fetch Use PC to get instruction and put it in the Instruction Register. Increment the PC by 4 and put the result back in the PC. Can be described succinctly using RTL "Register-Transfer Language" IR = Memory[PC]; PC = PC + 4; Can we figure out the values of the control signals? What is the advantage of updating the PC now?

Step 2: Instruction Decode and Register Fetch Read registers rs and rt in case we need them Compute the branch address in case the instruction is a branch RTL: A = Reg[IR[25-21]]; B = Reg[IR[20-16]]; ALUOut = PC + (sign-extend(IR[15-0]) << 2); We aren't setting any control lines based on the instruction type (we are busy "decoding" it in our control logic)

Step 3 (instruction dependent) ALU is performing one of three functions, based on instruction type Memory Reference: ALUOut = A + sign-extend(IR[15-0]); R-type: ALUOut = A op B; Branch: if (A==B) PC = ALUOut;

Step 4 (R-type or memory-access) Loads and stores access memory MDR = Memory[ALUOut]; or Memory[ALUOut] = B; R-type instructions finish Reg[IR[15-11]] = ALUOut; The write actually takes place at the end of the cycle on the edge

Write-back step Reg[IR[20-16]]= MDR; What about all the other instructions?

Summary:

Outra visão, fluxograma IR=Mem[PC] PC=PC+4 A=Reg[IR[25:21]] B=Reg[IR[20:16]] ALUout=PC+(SignExt(IR(15:0))<<2) ALUout=A op B Reg[IR[15:11]]=ALUout ALUout=A+SignExt(IR(15:0)) Mem(ALUout)=B MDR=Mem(ALUout) Reg[IR[15:11]]=MDR If A==B PC=ALUout PC=PC[31:28]& IR[25:0]<<2 5 1 6 2 8 9 7 3 4

Simple Questions How many cycles will it take to execute this code? lw $t2, 0($t3) lw $t3, 4($t3) beq $t2, $t3, Label #assume not add $t5, $t2, $t3 sw $t5, 8($t3) Label: ... What is going on during the 8th cycle of execution? In what cycle does the actual addition of $t2 and $t3 takes place?

Implementing the Control Value of control signals is dependent upon: what instruction is being executed which step is being performed Use the information we’ve acculumated to specify a finite state machine specify the finite state machine graphically, or use microprogramming Implementation can be derived from specification

Tabela dos sinais de controle

Graphical Specification of FSM W r i t e S o u c = 1 A L U B O p n d R g D s M m I a f h / J l E x y - b k ( ' ) Q 4 9 8 6 2 7 5 3 How many state bits will we need?

Finite State Machine for Control P C W r i t e o n d I D M m R g S u c A L U O p B s N 3 2 1 5 4 a f l

Desempenho desta máquina para o gcc lw sw Tipo R beq jump % 23 13 43 19 2 CPI 5 4 3 CPI = 0,23*5 + 0,13*4 + 0,43*4 + 0,19*3 + 0,02*3 = 4,02 Melhor do que se todas as instruções tomassem 5 ciclos Melhoria em MIPS (supor ck = 100 MHz) CPI = 4 -> 25 MIPS CPI = 5 -> 20 MIPS CPI = 1 (fazer tudo em um ciclo) -> 100 MIPS

PLA Implementation If I picked a horizontal or vertical line could you explain it?

ROM Implementation ROM = "Read Only Memory" values of memory locations are fixed ahead of time A ROM can be used to implement a truth table if the address is m-bits, we can address 2m entries in the ROM. our outputs are the bits of data that the address points to. m is the "heigth", and n is the "width" 0 0 0 0 0 1 1 0 0 1 1 1 0 0 0 1 0 1 1 0 0 0 1 1 1 0 0 0 1 0 0 0 0 0 0 1 0 1 0 0 0 1 1 1 0 0 1 1 0 1 1 1 0 1 1 1 m n

ROM Implementation How many inputs are there? 6 bits for opcode, 4 bits for state = 10 address lines (i.e., 210 = 1024 different addresses) How many outputs are there? 16 datapath-control outputs, 4 state bits = 20 outputs ROM is 210 x 20 = 1K x 20 bits (and a rather unusual size) Rather wasteful, since for lots of the entries, the outputs are the same — i.e., opcode is often ignored

ROM vs PLA Break up the table into two parts — 4 state bits tell you the 16 outputs, 24 x 16 bits of ROM — 10 bits tell you the 4 next state bits, 210 x 4 bits of ROM — Total: 4.3K bits of ROM PLA is much smaller — can share product terms — only need entries that produce an active output — can take into account don't cares Size is (#inputs  #product-terms) + (#outputs  #product-terms) For this example = (10x17)+(20x17) = 460 PLA cells PLA cells usually about the size of a ROM cell (slightly bigger)