1 / 23

Vom HW-Automaten zum Prozessor

Vom HW-Automaten zum Prozessor. Technische Grundlagen der Informatik Prof. Dr. Michael Löwe (Grundlage: Tanenbaum/Goodman. Computerarchitektur. 1999.). Inhalt. Hardware-Automaten Speicherorganisation Prozessoren und Speicher Datenweg Micro Controller Instruction Set Architecture

agnes
Télécharger la présentation

Vom HW-Automaten zum Prozessor

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Vom HW-Automaten zum Prozessor Technische Grundlagen der Informatik Prof. Dr. Michael Löwe (Grundlage: Tanenbaum/Goodman. Computerarchitektur. 1999.)

  2. Inhalt Hardware-Automaten Speicherorganisation Prozessoren und Speicher Datenweg Micro Controller Instruction Set Architecture Instruction Set Architecture Implementation Vom HW-Automaten zum Prozessor

  3. Clk Register (n Bit) Next State (n Bit) Input (m Bit) Last State Logische Funktion (m+n Bit  k+n Bit) Output (k Bit) Register (k Bit) Hardware-Automaten Vom HW-Automaten zum Prozessor

  4. ? Hardware-Automaten: Beispiele • Ampel • Bedieneinheit Videorecorder • Geldautomat • ..... Vom HW-Automaten zum Prozessor

  5. Logische Funktion (m+n Bit  k+n Bit) ----------------------------------- Speicherbaustein mit m+n Bit breitem Adressbus k+n Bit breitem Datenbus Input (m Bit) Adressbus Last State Register (n Bit) Datenbus Next State (n Bit) Output (k Bit) Clk Register (k Bit) Hardware-Automaten Vom HW-Automaten zum Prozessor

  6. D1 D2 D3 D4 D Q D Q D Q D Q Clk Clk Clk Clk Clk Q1 Q2 Q3 Q4 Register Vom HW-Automaten zum Prozessor

  7. IN WR CS D D D D Q Q Q Q OE Clk Clk Clk Clk A0 Dekodierer/ Multiplexer A1 Out Speicherorganisation ( Tri-State: IN = Out ) Vom HW-Automaten zum Prozessor

  8. 41 Bit 161 Bit 164 Bit A0 A0 A0 D0 A1 D A1 D A1 D1 A2 A2 D2 A3 A3 D3 WR CS OE WR CS OE WR CS OE Speicherbausteine Vom HW-Automaten zum Prozessor

  9. 164 Bit A0 D0 A1 D1 A2 D2 A3 D3 WR CS OE ? Speicher aus Bausteinen Verfügbar: 16 × 4 Bit Nachgefragt: • 32 × 4 Bit • 16 × 8 Bit Vom HW-Automaten zum Prozessor

  10. D0 D1 DatenBus D2 D3 164 Bit 164 Bit A0 A0 D0 D0 A1 A1 D1 D1 A2 A2 D2 D2 A3 A3 D3 D3 WR CS OE WR CS OE WR OE A0 A1 AdressBus A2 A3 A4 Speicher aus Bausteinen Schaltung für 32  4 Bit Vom HW-Automaten zum Prozessor

  11. 164 Bit 164 Bit A0 A0 D0 D0 A1 A1 D1 D1 A2 A2 D2 D2 A3 A3 D3 D3 WR CS OE WR CS OE Speicher aus Bausteinen D0 D1 DatenBus D2 D3 D4 D5 D6 D7 Schaltung für 16  8 Bit WR CS OE A0 A1 A2 AdressBus A3 Vom HW-Automaten zum Prozessor

  12. Speicherbausteine Random Access Memory (RAM) Statische RAMs (SRAM) Dynamische RAMs (DRAM) Read-Only-Memory (ROM) Vorfabrizierte ROMs Programmable ROM (PROM) Erasable PROM (EPROM) Hybride Speicherbausteine Electrically EPROMs (EEPROM) Flash Memory Vom HW-Automaten zum Prozessor

  13. Operanden-Stack Variablen-Stack Adressbus Datenbus Konstanten Programm Prozessor und Speicher Speicher Prozessor Vom HW-Automaten zum Prozessor

  14. C MAR B Zum und vom Speicher MDR MBR PC LV CPP SP TOS H Z A ALU Der Datenweg Typische ALU-Funktionen: C = A + B C = A  B C = A C = B C = B + 1 C = ShiftLeft(A, 8 Bit) C = -A ... Vom HW-Automaten zum Prozessor

  15. read, write, fetch C MAR B MPC MDR 512  32 Bit Steuerspeicher MBR PC 9 2 7 8 3 3 LV MIR Addr J ALU C M B CPP SP Decode 2* TOS H Z 1 A ALU Micro Controller: Übersicht Vom HW-Automaten zum Prozessor

  16. read, write, fetch C MAR B MPC MDR 512  32 Bit Steuerspeicher MBR PC 9 2 7 8 3 3 LV MIR Addr J ALU C M B CPP 9 2 7 8 3 3 SP Decode 2* TOS Addr J ALU C M B H Z 1 A ALU Micro Instruction Auswahl (mehrerer) Register für C-Bus zur Übernahme des ALU-Resultats Auswahl der ALU-Operation Adresse der nächsten auszu- führenden Micro Instruction Auswahl Register für B-Bus (dekodiert) als zweites Argument für die ALU Micro-GOTO bedingt und unbedingt Speichersteuerung (read | write); fetch Vom HW-Automaten zum Prozessor

  17. read, write, fetch C MAR B MPC MDR 512  32 Bit Steuerspeicher MBR PC 9 2 7 8 3 3 LV MIR Addr J ALU C M B CPP SP Decode 2* TOS H Z 1 A ALU Micro Controller: Ablaufsteuerung 1. Laden der nächsten Micro-Instruktion Adresse in MPC 2. Ausbreiten der Signale bis zum B-Bus 3. Ausbreiten der Signale bis zum C-Bus 4. Speichern der Ergebnisse 5. MPC für neuen Zyklus laden Vom HW-Automaten zum Prozessor

  18. read, write, fetch C MAR B MPC MDR 512  32 Bit Steuerspeicher MBR PC 9 2 7 8 3 3 LV MIR Addr J ALU C M B CPP SP Decode 2* TOS H Z 1 A ALU Micro Programme Label: R1 =..... = R <op R‘> <;(rd|wr)> <;fetch> <;goto label <;label‘>> Beispiele: H = MDR H = H + SP H = MBR << 8 SP = H or MDR; fetch TOS = MDR; goto Main Vom HW-Automaten zum Prozessor

  19. Adr 65.123..... Operanden-Stack SP (top) Variablen-Stack LV (bottom of top) Adressbus Datenbus Konstanten CPP (bottom) PC (random) Maschinen Programm Adr 0 Prozessor und Speicher Speicher Prozessor Vom HW-Automaten zum Prozessor

  20. C++ Programm Pascal Programm VB6 Programm C++ Compiler Pascal Compiler VB6 Compiler SW Maschinenprogramm HW Prozessor steuert Mikro- programm interpretiert Speicherzustand Programme und Maschinenprogramme Vom HW-Automaten zum Prozessor

  21. Typische Instruktionen Dyadische Operatoren: add, sub, or, ... Speicherbefehle: store, load (from/on stack) Sprünge: goto, goto on zero, ... Prozeduraufruf: call, return Byte1: Opcode Byte1: Opcode Byte2 + Byte3:Variable Index Byte1: Opcode Byte2 + Byte3: Offset vom PC Vom HW-Automaten zum Prozessor

  22. read, write, fetch C MAR B MPC MDR 512  32 Bit Steuerspeicher MBR PC B1: goto B2 + B3: Offset vom PC LV Addr J ALU C M B MIR CPP SP Decode 2* TOS H Z A 1 ALU Micro-Implementierung B1: add Main: PC = PC + 1; fetch; goto (MBR) B1: load B2: Index Vom HW-Automaten zum Prozessor

  23. B1: goto B2 + B3: Offset vom PC Micro-Implementierung MAR = SP = SP - 1; rd H = TOS MDR = TOS = MDR + H; wr; goto Main B1: add H = LV MAR = MBR + H; rd MAR = SP = SP + 1 PC = PC + 1; fetch; wr TOS = MDR; goto Main B1: load B2: Index MDR = PC - 1 PC = PC + 1; fetch H = MBR << 8 H = MBR or H PC = MDR + H; fetch wait; goto Main Main: PC = PC + 1; fetch; goto (MBR) Vom HW-Automaten zum Prozessor

More Related