Description of Single Cycle Computer (SCC)

Size: px
Start display at page:

Download "Description of Single Cycle Computer (SCC)"

Transcription

1 Descriptio of Sigle Cycle Computer (SCC) Refereces: Chapter 9 of M. Morris Mao ad Charles Kime, Logic ad Computer Desig Fudametals, Pearso Pretice Hall, 4 th Editio, 28. Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig

2 Itroductio Computer Specificatio Istructio Set Architecture (ISA) - the specificatio of a computer's appearace to a programmer at its lowest level Computer Architecture - a high-level descriptio of the hardware implemetig the computer derived from the ISA The architecture usually icludes additioal specificatios such as speed/performace, cost, ad reliability Itroductio Simple computer architecture decomposed ito: Datapath: performig operatios (i.e., data maipulatio) A set of registers Microoperatios performed o the data stored i the registers A cotrol iterface Cotrol uit: cotrollig datapath operatios Programmable & No-programmable Cotrol iputs Data iputs Cotrol uit Status sigals Cotrol sigals Datapath Cotrol outputs Data outputs 2

3 Datapath Example Load eable Write D data A address A select address select Register file: Four parallel-load regs Two mux-based register selectors Register destiatio decoder Microoperatio implemetatio Mux for exteral costat iput uses A ad with exteral address ad data outputs Fuctio Uit: ALU ad Shifter with Mux F for output select Mux D for exteral data iput Logic for geeratig status bits: V, C, N, 2 3 Decoder D address 2 Costat i Destiatio select V C N Load Load Load Load M select us A MD select us D MUX MUX D us 2 2 A data A G select H select 4 A 2 S 2: C S i Arithmetic/logic IR Shifter IL uit (ALU) G H ero Detect MF select R R R2 R3 MUX F F 2 3 MUX Fuctio uit 2 3 MUX data Register file Address Out Data Out Data I Datapath Example: Performig a Microoperatio Microoperatio: R R + R2 Apply to A select to place cotets of R oto us A Apply to select to place cotets of R2 oto data ad apply to M select to place data o us Apply to G select to perform additio G = us A + us Apply to MF select ad to MD select to place the value of G oto US D Apply to Destiatio select to eable the Load iput to R Apply to Load Eable to force the Load iput to R to so that R is loaded o the clock pulse (ot show) The overall microoperatio requires clock cycle Load eable Write D data 2 3 Decoder D address 2 Costat i Destiatio select V C N Load Load Load Load M select us A MD select MUX D us D MUX us 2 2 A data A G select H select 4 A 2 S 2: C S i Arithmetic/logic IR Shifter IL uit (ALU) G H ero Detect MF select R R R2 R3 MUX F F A address A select 2 3 MUX address 2 3 Fuctio uit select MUX Register file data Address Out Data Out Data I 3

4 Datapath Example: Key Cotrol Actios for Microoperatio Alteratives Various microoperatios: Perform a shift microoperatio: apply to MF select Use a costat i a micro-operatio usig us : apply to M select Provide a address ad data for a memory or output write microoperatio apply to Load eable to prevet register loadig Provide a address ad obtai data for a memory or output read microoperatio apply to MD select For some of the above, other cotrol sigals become do't cares Load eable Write D data 2 3 Decoder D address 2 Costat i Destiatio select V C N Load Load Load Load M select R R R2 R3 us A MD select MUX D us D MUX A address us A select 2 2 MUX A data A G select H select 4 A 2 S 2: C S i Arithmetic/logic IR Shifter IL uit (ALU) G H ero Detect MF select MUX F Fuctio uit F 2 3 address select 2 3 MUX Register file data Address Out Data Out Data I Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig 4

5 Arithmetic Logic Uit (ALU) Decompose the ALU ito: A arithmetic circuit & A logic circuit A selector to pick betwee the two circuits Ci Ci Ci Ci + Ai i S S Ai i S S Oe stage of arithmetic circuit 2-to- MUX Gi Ai i S Oe stage of logic circuit S S S2 Arithmetic Circuit Arithmetic circuit desig Decompose the arithmetic circuit ito: A -bit parallel adder A logic block that selects four choices for iput to the adder There are oly four fuctios of to select as Y i G = A + Y +C i : Y C i = C i = G = A G = A + G = A + G = A G = A + G = A + + G = A + + G = A Ci A iput logic S X Y -bit parallel adder G= X+ Y + Ci Arithmetic operatios S Cout 5

6 4-it asic Left/Right Shifter 3 2 IR IL 2 M S UX 2 M S UX 2M S UX S 2 M UX S 2 H3 H2 H H Serial Iputs: I R for right shift I L for left shift Shift Fuctios: (S, S ) = Pass uchaged Right shift Left shift Uused arrel Shifter D3 D2 D D S S 3 S S S S 3 2 S S 3 2 S S M M M M UX UX UX UX Y3 Y2 Y Y A rotate is a shift i which the bits shifted out are iserted ito the positios vacated The circuit rotates its cotets left from to 3 positios depedig o S: S = positio uchaged S = rotate left by 2 positios S = rotate left by positios S = rotate left by 3 positios 6

7 Example 8-bit: Layer shifts by, 4 Layer 2 shifts by, 2 Layer 3 shifts by, Large barrel shifters ca be costructed usig: Layers of multiplexers 2-dimesioal array circuits desiged at the electroic level Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig 7

8 Datapath Represetatio I the register file: Select iputs for multiplexers => A address & address Decoder iput => D address Load eable => write Iput data to the registers => D data Multiplexer outputs => A data & data The register file ow appears like a memory based o clocked flipflops FS? Costat i M select FS V C N m m 4 MD select D data Write D address 2 m x Register file A address A data A us A address data Fuctio uit F MUX D MUX m us Address out Data out Data i Defiitio of Fuctio Select (FS) Codes FS(3:) MF Select G H Select(3:) Select(:) FS Microoperatio V C N G select 4 A ero Detect MF select F A S 2: C i Arithmetic/logic uit (ALU) G MUX F H select 2 S IR Shifter IL H Fuctio uit XX XX XX XX XX XX XX XX X XX X XX X XX X XX XXXX XXXX XXXX F A F A + F A + F A + + F A + F A + + F A - F A F A F A F A F A F F sr F sl oolea Equatios: MF i = F 3 F 2 G i = F i H i = F i 8

9 The Cotrol Word The datapath has may cotrol iput sigals, ca be orgaized ito a cotrol word To execute a microistructio, we apply cotrol word values for a clock cycle DA AA A M Cotrol word FS DA D Address, AA A Address A Address, M Mux FS Fuctio Select, MD Mux D RW Register Write M R D W RW 5 DA AA V C N Write Costat i M6 D data D address 8x Register file A address A data MD A us A Fuctio uit us D address data MUX MUX D us 5 4 FS A 7 Address out Data out Data i Cotrol Word Ecodig DA, AA, A M FS MD RW Fuctio Code Fuctio Code Fuctio Code Fuctio Code Fuctio Code R Register F A Fuctio No write R Costat F A + Data I Write R2 F A + R3 F A + + R4 F A + R5 F A + + R6 F A - R7 F A F A F A F A F A F F sr F sl 9

10 Microoperatios for the Datapath Symbolic & iary Represetatio Microoperatio DA AA A M FS MD RW R R2 R3 R R2 R3 Register F = A + + Fuctio Write R4 sl R6 R4 R6 Register F = sl Fuctio Write R7 R7 + R7 R7 Register F = A + Fuctio Write R R + 2 R R Costat F = A + Fuctio Write Data out R3 R3 Register No Write R4 Data i R4 Data i Write R5 R5 R R Register F = A Fuctio Write Microoperatio DA AA A M FS MD RW R R2 R3 R4 s l R6 R7 R7 + R R + 2 Data out R3 R4 Data i R5 XXX XXX XXX XXX XXX XXXX X XXX XXX X XXXX Datapath Simulatio clock DA AA A FS Costat_i X 2 M Address_out Data_out Data_i MD RW reg reg reg2 reg3 reg4 reg5 reg6 reg7 Status_bits X X 7 8

11 Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig Istructio Set Architecture (ISA) for Simple Computer (SC) Istructios are stored i RAM or ROM as a program, the addresses for istructios are provided by a program couter (PC) Cout up or load a ew address The PC ad associated cotrol logic are part of the Cotrol Uit A typical istructio specifies: Operads to use Operatio to be performed Where to place the result, or which istructio to execute ext Executig a istructio Activate the ecessary sequece of operatios specified by the istructio e cotrolled by the cotrol uit ad performed i: Datapath Cotrol uit Exteral hardware such as memory or iput/output

12 ISA Examples RISC (Reduced Istructio Set Computer) Digital Alpha Su Sparc MIPS RX IM PowerPC HP PA/RISC CISC (Complex Istructio Set Computer) Itel x86 Motorola 68 DEC VAX VLIW (Very Large Istructio Word) Itel Itaium ISA: Storage Resources "Harvard architecture : separate istructio ad data memories Permit use of sigle clock cycle per istructio implemetatio Istructio memory 2 5 x 6 Program couter (PC) Register file 8 x 6 Due to use of "cache" i moder computer architectures, it is a fairly realistic model Data memory 2 5 x6 2

13 ISA: Istructio Formats The three formats are: Register, Immediate, ad Jump/rach Opcode Destiatio register (DR) (a) Register (c) Jump ad rach Source register A (SA) Source register (S) Opcode Destiatio register (DR) (b) Immediate Source register A (SA) Operad (OP) Opcode Address (AD) (Left) Source register A (SA) Address (AD) (Right) All formats cotai a Opcode field i bits 9 through 5. The Opcode specifies the operatio to be performed ISA: Istructio Format - Register Opcode Destiatio register (DR) Source register A (SA) Source register (S) (a) Register This format supports: R R2 + R3 R sl R2 Three 3-bit register fields: DR - destiatio register (R i the examples) SA - the A source register (R2 i the first example) S - the source register (R3 i the first example ad R2 i the secod example) Why is R2 i the secod example S istead of SA? 3

14 ISA: Istructio Format - Immediate Opcode Destiatio register (DR) (b) Immediate Source register A (SA) Operad (OP) This format supports: R R2 + 3 The Source Register field is replaced by a Operad field OP specifyig a costat. (3-bit costat, values from to 7) The costat: ero-fill (o the left of) the operad to form 6-bit costat 6-bit represetatio for values through 7 ISA: Istructio Format - Jump & rach Opcode Address (AD) (Left) Source register A (SA) Address (AD) (Right) (c) Jump ad rach This istructio supports chages i the sequece of istructio executio by addig a exteded, 6-bit, siged 2 s-complemet address offset to the PC value The SA field: permits jumps ad braches o N or based o the cotets of Source register A The Address (AD) field (6-bit) replaces the DR ad S fields Example: Suppose that a jump for the Opcode ad the PC cotais 45 ( ) ad AD cotais -2 (). The the ew PC value will be: + ( ) = (i.e., 45 + (-2) = 33) 4

15 ISA: Istructio Specificatios Istr uctio Opcode Memoic Format Descriptio St atus its Move A MOVA RD,RA R[DR] R[SA] N, Icremet INC RD,RA R[DR] R[SA] + N, Add ADD RD,RA,R R[DR] R[SA] + R[ S] N, Subtract SU RD,RA,R R[DR] R[SA] - R[S] N, Decremet DEC RD,RA R[DR] R[SA] - N, AND AND RD,RA,R R[DR] R[SA] R[S ] N, OR OR RD,RA,R R[DR] R[SA] R[S] N, Exclusive OR XOR RD,RA,R R[DR] R[SA] R[S] N, NO T NO T RD,RA R[DR] R[SA ] N, Move MOV RD,R R[DR] R[S] Shift Right SHR RD,R R[DR] sr R[S] Shift Left SHL RD,R R[DR] sl R[S] Load Immediate LDI RD, OP R[DR] zf OP Add Immediate ADI RD,RA,OP R[DR] R[SA] + zf OP Load LD RD,RA R[DR] M[R[SA]] Store ST RA,R M[R[SA]] R[S] rach o ero R RA,AD if (R[SA] = ) PC PC + se A D rach o Negative RN RA,AD if (R[SA] < ) PC PC + se A D Jump JMP RA PC R[SA] ISA: Example Istructios ad Data i Memory Memory Represetatio of Istructio ad Data Decimal Ad dress Memory Cotets Decimal Opcode Other Field Operatio 25 5 (Subtract) DR:, SA:2, S:3 R R2 - R (Store ) SA:4, S:5 M[ R4] R (Add Im mediate) DR: 2, SA :7, OP :3 R 2 R (rach o ero ) AD: 44, SA:6 If R6 =, PC PC Data = 92. After executio of istructio i 35, Data = 8. 5

16 Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig V CN rach Cotrol PC IR(8:6) IR(2:) Exted Sigle-Cycle Hardwired Cotrol: J L P C D A A A A Address Istructio memory Istructio Istructio decoder ased o the ISA defied, desig a computer architecture to support the ISA The architecture is to fetch ad execute each istructio i a sigle clock cycle ero fill IR(2:) M F M R M J S D W W L P C CONTROL RW DA AA Costat i FS V C N us A A MD us D D Register file A MUX us Fuctio uit F MUX D A M DATAPATH Address out Data out MW Data_i Address Data i Data memory Data out 6

17 The Cotrol Uit Datapath: the Data Memory has bee attached to the Address Out, Data Out, ad Data I lies of the Datapath. Cotrol Uit: The MW iput to the Data Memory is the Memory Write sigal from the Cotrol Uit. The Istructio Memory address iput is provided by the PC ad its istructio output feeds the Istructio Decoder. ero-filled IR(2:) becomes Costat I Exteded IR(8:6) IR(2:) ad us A are address iputs to the PC. The PC is cotrolled by rach Cotrol logic Program Couter (PC) Fuctio PC fuctio is based o istructio specificatios ivolvig jumps ad braches: rach o ero R if (R[SA] = ) PC PC + se A D rach o Negative RN if (R[SA] < ) PC PC + sea D Jump JMP PC R[SA ] The first two trasfers require additio to the PC of: Address Offset = Exteded IR(8:6) IR(2:) The third trasfer requires that the PC be loaded with: Jump Address = us A = R[SA] I additio to the above register trasfers, the PC must implemet the coutig fuctio: PC PC + 7

18 PC Fuctio (Cotd.) rach Cotrol determies the PC trasfers based o five iputs: N, egative ad zero status bits PL load eable for the PC J Jump/rach select: If J =, Jump, else rach C rach Coditio select: If C =, brach for N =, else brach for =. PL J C PC Operatio X X Cout Up X Jump rach o Negative (else Cout Up) rach o ero (else Cout Up) Istructio Decoder Coverts the istructio ito the sigals ecessary to cotrol the computer durig the sigle cycle executio, combiatioal Iputs: the 6-bit Istructio Outputs: cotrol sigals DA, AA, ad A: Register file addresses (IR (8:)) simply pass-through sigals: DA = DR, AA = SA, ad A = S FS: Fuctio Uit Select M ad MD: Multiplexer Select Cotrols RW ad MW: Register file ad Data Memory Write Cotrols PL, J, ad C: PC Cotrols Observe that for other tha braches ad jumps, FS = IR(2:9) The other cotrol sigals should deped as much as possible o IR(5:3) 8

19 Istructio Decoder (Cotd.) Truth Table for Istructio Decoder Logic Istructio Fuctio Type Istructio its Cotrol Word its M MD RW MW PL J C. Fuctio uit operatios usig registers X 2. Memory read X 3. Memory write X 4. Fuctio uit operatios usig register ad costat X 5. Coditioal brach o zero () X X X X X X X X X X X 6. Coditioal brach o egative X X (N) 7. Ucoditioal Jump X X X X Istructio Decoder (Cotd.) Istructio types are based o the cotrol blocks ad the seve cotrol sigals to be geerated (M, MD, RW, MW, PL, J, C): Datapath ad Memory Cotrol (types -4) Mux Memory ad Mux D PC Cotrol (types 5-7) it 5 = it 4 = => PL it 3 => J. it 9 was use as C which cotradicts FS = eeded for braches. To force FS() to for braches, it 9 ito FS() is disabled by PL. 9

20 Istructio Decoder (Cotd.) The ed result by use of the types, careful assigmet of codes, ad use of do't cares, yields very simple logic: This completes the desig of most of the essetial parts of the sigle-cycle simple computer Istructio Opcode DR SA S DA AA A M FS MD RW MW PL J C Cotrol word Example Istructio Executio Decodig, cotrol iputs ad paths show for ADI, LD ad R o ext 6 slides 2

21 Decodig for ADI Istructio Opcode DR SA S DA 6 4 AA 3 A M 9 6 FS MD RW MW PL J C 2 Cotrol word V CN rach Cotrol J L P C Icremet PC D A A A A PC Address Istructio memory Istructio IR(8:6) IR(2:) Exted Istructio decoder ero fill IR(2:) M F M R M J S D W W L P C CONTROL RW DA AA Costat i FS V C N us A D Register file A A MUX us + Fuctio uit F A M Cotrol Iputs ad Paths for ADI Address out Data out MW Data i Address Data memory Data out No Write Data i MD us D MUX D DATAPATH 2

22 Decodig for LD Istructio Opcode DR SA S DA 6 4 AA 3 A M 9 6 FS MD RW MW PL J C 2 Cotrol word V CN rach Cotrol PC IR(8:6) IR(2:) Exted Cotrol Iputs ad Paths for LD J L P C Icremet PC D A A A A Address Istructio memory Istructio Istructio decoder ero fill IR(2:) M F M R M J S D W W L P C CONTROL RW DA AA Costat i FS V C N us A D Register file A A MUX us Fuctio uit F A M Address out Data out MW Data i Address Data i Data memory Data out No Write MD us D MUX D DATAPATH 22

23 Decodig for R Istructio Opcode DR SA S DA 6 4 AA 3 A M 9 6 FS MD RW MW PL J C 2 Cotrol word V CN rach Cotrol J L P C rach o D A A A A PC Address Istructio memory Istructio IR(8:6) IR(2:) Exted Istructio decoder ero fill IR(2:) M F M R M J S D W W L P C CONTROL RW DA AA Costat i FS V C N us A No Write D Register file A A MUX us Fuctio uit F A M Cotrol Iputs ad Paths for R Address out Data out MW Data i Address Data memory Data out No Write Data i MD us D MUX D DATAPATH 23

24 Abstract View of Critical Path Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig 24

25 Sigle-Cycle Computer Issues Shortcomig of Sigle Cycle Desig Complexity of istructios executable i a sigle cycle is limited Accessig both a istructio ad data from a simple sigle memory impossible A log worst case delay path limits clock frequecy ad the rate of performig istructios Hadlig of Shortcomigs The first two shortcomigs ca be hadled by the multiple-cycle computer The third shortcomig is dealt with by usig a techique called pipeliig described i later lectures Multiple-Cycle Computer Covertig the sigle-cycle computer ito a multiple-cycle computer ivolves: Modificatios to the datapath/memory Modificatio to the cotrol uit Desig of a multiple-cycle hardwired cotrol 25

26 V CN rach Cotrol PC IR(8:6) IR(2:) Exted J L P C D A A A A Address Istructio memory Istructio Istructio decoder ero fill IR(2:) M F M R M J S D W W L P C CONTROL Sigle-Cycle Simple Computer (SC) RW DA AA Costat i FS V C N us A A MD us D D Register file A MUX us Fuctio uit F MUX D A M DATAPATH Address out Data out MW Data i Address Data i Data memory Data out Datapath Modificatios New Istructio Path Use a sigle memory for both istructios ad data Requires ew MUX M with cotrol sigal MM to select betwee the istructio address from the PC ad the data address Ist. & Data Address Mux Requires path from Memory Data Out to the istructio register i the cotrol uit Ist. & Data Memory 26

27 Datapath Modificatios (Cotiued) Additioal registers eeded to hold operads betwee cycles Add 8 temporary storage registers to the Register File Register File becomes 6 x 6 Addresses to Register File icrease from 3 to 4 bits Register File addresses come from: The istructio for the Storage Resource registers ( to 7) The cotrol word for the Temporary Storage registers (8 to 5) Add Register Address Logic to the Register File to select the register address sources Three ew cotrol fields for register address source selectio ad temporary storage addressig: DX, AX, X Register Address Logic 6 x 6 Register File 27

28 Cotrol Uit Modificatios Must hold istructio over the multiple cycles to draw o istructio iformatio throughout istructio executio Requires a Istructio Register (IR) to hold the istructio Load cotrol sigal IL Requires the additio of a "hold" operatio to the PC sice it oly couts up to obtai a ew istructio New ecodig for the PC operatios uses 2 bits Add "hold" operatio Istructio Register IR 28

29 Overview Part Datapaths Itroductio Datapath Example Arithmetic Logic Uit (ALU) Shifter Datapath Represetatio ad Cotrol Word Part 2 A Simple Computer Istructio Set Architecture (ISA) Sigle-Cycle Hardwired Cotrol Part 3 Multiple Cycle Hardwired Cotrol Sigle Cycle Computer Issues Sequetial Cotrol Desig Sequetial Cotrol Desig To cotrol microoperatios over multiple cycles, a Sequetial Cotrol replaces the Istructio Decoder Iput: Opcode, Status its, Cotrol State Output: Cotrol Word (Modified Datapath Cotrol part) Next State: Cotrol Word (New Sequecig Cotrol part) Cosists of: Register to store the Cotrol State Combiatioal Logic to geerate the Cotrol Word (both sequecig ad datapath cotrol parts) The Combiatioal Logic is quite complex so we assume that it is implemeted by usig a PLA or sythesized logic ad focus o ASM level desig 29

30 Cotrol State Register Combiatioal Cotrol Logic New/ Modified Cotrol Word Cotrol Word NS PS I L Sequecig M DX AX X FS Datapath Datapath part: field MM added, ad fields DX, AX, ad X replace DA, AA, ad A, respectively If the MS of a field is, e.g., AX = XXX, the AA is cocateated with SA (3bits) field i the IR If the MS of a field is, e. g. AX =, the AA = Sequecig part: IL cotrols the loadig of the IR PS cotrols the operatios of the PC NS gives the ext state of the Cotrol State register E.g., NS is 4 bits, the legth of the Cotrol State register - 6 states are viewed as adequate for this desig M D R M M W M W 3

31 Ecodig for Datapath Cotrol DX AX X Code M Code FS Code MD RW MM MW Code R[DR] R[SA] R[S] XXX Register F A FUt No write Address Out No write R8 R8 R8 Costat F A + Data I Write PC Write R9 R9 R9 F A + R R R Uused R R R Uused R2 R2 R2 F A + + R3 R3 R3 F A R4 R4 R4 Uused R5 R5 R5 F A ^ F A v F A + F A F F sr F sl Uused Ecodig for Sequecig Cotrol NS PS IL Next State Actio Code Actio Code Gives ext state of Cotrol State Register Hold PC No load Ic PC Load istr. rach Jump 3

32 ASM Charts for Sequetial Cotrol A istructio requires two steps: Istructio fetch obtaiig a istructio from memory Istructio executio the executio of a sequece of microoperatios to perform istructio processig Due to the use of the IR, these two steps require a miimum of two clock cycles ISA: Istructio Specificatios ad ASM charts for the istructios (that all require two clock cycles) A vector decisio box is used for the opcode Scalar decisio boxes are used for the status bits ISA: Istructio Specificatios (for referece) Istructio Speci ficatios for the SimpleComputer - Part Istr uctio Opcode Memoic Format Descriptio St atus its Move A MOVA RD,RA R[DR] R[SA] N, Icremet INC RD,RA R[DR] R[SA] + N, Add ADD RD,RA,R R[DR] R[SA] + R[ S] N, Subtract SU RD,RA,R R[DR] R[SA] - R[S] N, Decremet DEC RD,RA R[DR] R[SA] - N, AND AND RD,RA,R R[DR] R[SA] R[S ] N, OR OR RD,RA,R R[DR] R[SA] R[S] N, Exclusive OR XOR RD,RA,R R[DR] R[SA] R[S] N, NO T NO T RD,RA R[DR] R[SA ] N, 32

33 ASM Chart for 2-Cycle Istructios - Part R[DR] R[SA] R[DR] R[SA] + R[S] R[DR] R[SA] R[DR] R[SA] v R[S] R[DR] R[SA] PC PC + R[DR] R[SA]+ R[DR] R[SA] + R[S] + R[DR] R[SA] R[S] R[DR] R[SA] + R[S] IN F EX IR M[PC] Opcode ISA: Istructio Specificatios (for referece) Istructio Specificatios for the Simple Computer - Part 2 Istr uctio Opcode Memoic Format Descriptio St atus its Move MOV RD,R R[DR] R[S] Shift Right SHR RD,R R[DR] sr R[S] Shift Left SHL RD,R R[DR] sl R[S] Load Immediate LDI RD, OP R[DR] zf OP Add Immediate ADI RD,RA,OP R[DR] R[SA] + zf OP Load LD RD,RA R[DR] M[SA] Store ST RA,R M[SA] R[S] rach o ero R RA,AD if (R[SA] = ) PC PC + se A D rach o Negative RN RA,AD if (R[SA] < ) PC PC + se A D Jump JMP RA PC R[SA] 33

34 Portio i Red duplicated from previous ASM chart IN F IR M[PC] EX Opcode PC PC + R[DR] M[ R[SA] ] R[DR] zf OP R[DR] R[S] M[ R[SA] ] R[S] ASM Chart for 2-Cycle Istructios - Part 2 R[DR] R[SA] + zf OP To INF N PC PC + se AD PC R[SA] Chapter Part 2 State Table for 2-Cycle Istructios State Opcode Iputs VCN Next st ate I L Outputs P S DX AX X M FS M D R M M W M W Comme ts INF XXXXXXX XXXX EX XXXX XXXX XXXX X XXXX X IR M[PC ] EX XXXX INF XXX XXX XXXX X X MOVA R[DR] R[SA]* EX XXXX INF XXX XXX XXXX X X INC R[DR] R[SA] + * EX XXXX INF XXX XXX XXX X ADD R[DR] R[SA] + R[S]* EX XXXX INF XXX XXX XXX X SU R[DR} R[SA] + R[ S] + * EX XXXX INF XXX XXX XXXX X X DEC R[DR] R[SA] + (- )* EX XXXX INF XXX XXX XXX X AND R[DR] R[SA] ^ R[S]* EX XXXX INF XXX XXX XXX X OR R[DR] R[SA] v R[S]* EX XXXX INF XXX XXX XXX X XOR R[DR] R[SA] + R[S]* EX XXXX INF XXX XXX XXXX X X NOT R[DR] R [ SA ] * EX XXXX INF XXX XXXX XXX X MOV R[DR] R[S]* EX XXXX INF XXX XXX XXXX X XXXX LD R[DR] M[R[SA]]* EX XXXX INF XXXX XXX XXX XXXX X ST M[R[SA]] R[S]* EX XXXX INF XXX XXXX XXXX LDI R[DR] zf OP* EX XXXX INF XXX XXX XXXX ADI R[DR] R[SA] + zf OP* EX XXX INF XXXX XXX XXXX X X R PC PC + se AD EX XXX INF XXXX XXX XXXX X X R PC PC + EX XXX INF XXXX XXX XXXX X X RN PC PC + se AD EX XXX INF XXXX XXX XXXX X X RN PC PC + EX XXXX INF XXXX XXX XXXX X X JMP PC R[SA] * For this state ad iput combiatios, PC PC+ also occurs 34

35 3-Process ASM VHDL Code etity cotroller is port ( opcode : i std_logic_vector(6 dowto ); reset, clk : i std_logic; zero, egative : i std_logic; IL, M, MD, MM, RW, MW : out std_logic; PS : out std_logic_vector( dowto ); DX, AX, X, FS : out std_logic_vector(3 dowto ); ); ed cotroller; architecture ehavioral of cotroller is type state_type is (RES, FTH, EX); sigal cur_state, ext_state : state_type; begi state_register:process(clk, reset) begi if (reset='') the cur_state<=res; elsif (clk'evet ad clk='') the cur_state<=ext_state; ed if; ed process; 3-Process ASM VHDL Code out_fuc: process (cur_state, opcode, zero, egative) begi (IL,PS, M, FS, MD, RW, MW, MM) <= std_logic_vector'(x""); FS<=""; case cur_state is whe RES => ext_state <= FTH; whe FTH => -- set the cotrol vector values ext_state <= EXE; whe EXE => case opcde is: whe +> ed process; ed ehavioral; 35

36 ASM Chart for Multiple its Right Shift EX Opcode R8 R[SA] R8 used to perform shifts EX R9 used to store ad decremet shift cout EX2 R9 zf OP Opcode ero test i EX is to determie if the shift amout is ; if so, goes to state INF Opcode R8 sr R8 EX3 R9 R9 - Opcode EX4 PC PC+ Opcode R[DR] R8 To INF State Table For Multiple its Right Shift St at e Opcode Iputs VCN Next st at e Outputs I L PS DX AX X M FS MD RW MM M W Co mmets EX XXX EX XXX XXXX X X SRM R8 R[SA], : EX EX XXX INF XXX XXXX X X SRM R8 R[SA],: INF* EX XXX EX2 XXXX XXXX X SRM R9 zf OP, : EX2 EX XXX INF XXXX XXXX X SRM R9 zf OP,: INF* EX2 XXXX EX3 XXXX X SRM R8 sr R8, EX3 EX3 XXX EX2 XXXX X X SRM R9 R9 -, : EX2 EX3 XXX EX4 XXXX X X SRM R9 R9 -,: EX4 EX4 XXXX INF XXX XXXX X X SRM R[DR] R8, INF* * For this state ad iput combiatios, PC PC+ also occurs 36

37 Summary Cocept of Datapath for implemetig computer microistructios Cotrol word provides a meas of orgaizig the cotrol of the microoperatios Cocept of ISA ad istructio formats ad operatios of Simple Computer (SC) Sigle clock cycle vs. multiple cycle (istructio fetch + istructio executio) 37

ECE 3401 Lecture 20. Microprogramming (III) Overview. Single-Cycle Computer Issues. Multiple-Cycle Computer. Single-Cycle SC

ECE 3401 Lecture 20. Microprogramming (III) Overview. Single-Cycle Computer Issues. Multiple-Cycle Computer. Single-Cycle SC Overview ECE 34 Lecture 2 icroprogramming (III) Part Datapaths Introduction Datapath Example Datapath Representation and Control Word Part 2 A Simple Computer Set Architecture (ISA) Single-Cycle Hardwired

More information

EE 459/500 HDL Based Digital Design with Programmable Logic. Lecture 13 Control and Sequencing: Hardwired and Microprogrammed Control

EE 459/500 HDL Based Digital Design with Programmable Logic. Lecture 13 Control and Sequencing: Hardwired and Microprogrammed Control EE 459/500 HDL Based Digital Desig with Programmable Logic Lecture 13 Cotrol ad Sequecig: Hardwired ad Microprogrammed Cotrol Refereces: Chapter s 4,5 from textbook Chapter 7 of M.M. Mao ad C.R. Kime,

More information

Chapter 9 Computer Design Basics

Chapter 9 Computer Design Basics Logic and Computer Design Fundamentals Chapter 9 Computer Design asics Part 2 A Simple Computer Charles Kime & Thomas Kaminski 2008 Pearson Education, Inc. (Hyperlinks are active in View Show mode) Overview

More information

CSC 220: Computer Organization Unit 11 Basic Computer Organization and Design

CSC 220: Computer Organization Unit 11 Basic Computer Organization and Design College of Computer ad Iformatio Scieces Departmet of Computer Sciece CSC 220: Computer Orgaizatio Uit 11 Basic Computer Orgaizatio ad Desig 1 For the rest of the semester, we ll focus o computer architecture:

More information

Chapter 10 Computer Design Basics

Chapter 10 Computer Design Basics Logic and Computer Design Fundamentals Chapter 10 Computer Design Basics Part 2 A Simple Computer Charles Kime & Thomas Kaminski 2004 Pearson Education, Inc. Terms of Use (Hyperlinks are active in View

More information

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Part A Datapath Design

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Part A Datapath Design COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter The Processor Part A path Desig Itroductio CPU performace factors Istructio cout Determied by ISA ad compiler. CPI ad

More information

Appendix D. Controller Implementation

Appendix D. Controller Implementation COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Appedix D Cotroller Implemetatio Cotroller Implemetatios Combiatioal logic (sigle-cycle); Fiite state machie (multi-cycle, pipelied);

More information

Elementary Educational Computer

Elementary Educational Computer Chapter 5 Elemetary Educatioal Computer. Geeral structure of the Elemetary Educatioal Computer (EEC) The EEC coforms to the 5 uits structure defied by vo Neuma's model (.) All uits are preseted i a simplified

More information

Chapter 5: Processor Design Advanced Topics. Microprogramming: Basic Idea

Chapter 5: Processor Design Advanced Topics. Microprogramming: Basic Idea 5-1 Chapter 5 Processor Desig Advaced Topics Chapter 5: Processor Desig Advaced Topics Topics 5.3 Microprogrammig Cotrol store ad microbrachig Horizotal ad vertical microprogrammig 5- Chapter 5 Processor

More information

Microprogrammed Control

Microprogrammed Control Calcolatori Elettroici e Sistemi Operativi Microprogrammed Microprogrammed Iputs (state) Status sigals (from datapath) NS = δ(s,i) = ((S),I) O = λ(s) Next state Outputs sigals (to datapath) Microprogrammed

More information

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Single-Cycle Disadvantages & Advantages

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Single-Cycle Disadvantages & Advantages COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 4 The Processor Pipeliig Sigle-Cycle Disadvatages & Advatages Clk Uses the clock cycle iefficietly the clock cycle must

More information

Chapter 4 The Datapath

Chapter 4 The Datapath The Ageda Chapter 4 The Datapath Based o slides McGraw-Hill Additioal material 24/25/26 Lewis/Marti Additioal material 28 Roth Additioal material 2 Taylor Additioal material 2 Farmer Tae the elemets that

More information

CMSC Computer Architecture Lecture 3: ISA and Introduction to Microarchitecture. Prof. Yanjing Li University of Chicago

CMSC Computer Architecture Lecture 3: ISA and Introduction to Microarchitecture. Prof. Yanjing Li University of Chicago CMSC 22200 Computer Architecture Lecture 3: ISA ad Itroductio to Microarchitecture Prof. Yajig Li Uiversity of Chicago Lecture Outlie ISA uarch (hardware implemetatio of a ISA) Logic desig basics Sigle-cycle

More information

End Semester Examination CSE, III Yr. (I Sem), 30002: Computer Organization

End Semester Examination CSE, III Yr. (I Sem), 30002: Computer Organization Ed Semester Examiatio 2013-14 CSE, III Yr. (I Sem), 30002: Computer Orgaizatio Istructios: GROUP -A 1. Write the questio paper group (A, B, C, D), o frot page top of aswer book, as per what is metioed

More information

Computer Architecture. Microcomputer Architecture and Interfacing Colorado School of Mines Professor William Hoff

Computer Architecture. Microcomputer Architecture and Interfacing Colorado School of Mines Professor William Hoff Computer rchitecture Microcomputer rchitecture ad Iterfacig Colorado School of Mies Professor William Hoff Computer Hardware Orgaizatio Processor Performs all computatios; coordiates data trasfer Iput

More information

Lecture 3. RTL Design Methodology. Transition from Pseudocode & Interface to a Corresponding Block Diagram

Lecture 3. RTL Design Methodology. Transition from Pseudocode & Interface to a Corresponding Block Diagram Lecture 3 RTL Desig Methodology Trasitio from Pseudocode & Iterface to a Correspodig Block Diagram Structure of a Typical Digital Data Iputs Datapath (Executio Uit) Data Outputs System Cotrol Sigals Status

More information

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated.

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated. 8-1 Name Binary code IDLE 000 Register operation or output R 0 RUN Condition (a) State box (b) Example of state box (c) Decision box IDLE R 0 From decision box START Register operation or output PC 0 (d)

More information

Lecture 2. RTL Design Methodology. Transition from Pseudocode & Interface to a Corresponding Block Diagram

Lecture 2. RTL Design Methodology. Transition from Pseudocode & Interface to a Corresponding Block Diagram Lecture 2 RTL Desig Methodology Trasitio from Pseudocode & Iterface to a Correspodig Block Diagram Structure of a Typical Digital Data Iputs Datapath (Executio Uit) Data Outputs System Cotrol Sigals Status

More information

CMSC Computer Architecture Lecture 2: ISA. Prof. Yanjing Li Department of Computer Science University of Chicago

CMSC Computer Architecture Lecture 2: ISA. Prof. Yanjing Li Department of Computer Science University of Chicago CMSC 22200 Computer Architecture Lecture 2: ISA Prof. Yajig Li Departmet of Computer Sciece Uiversity of Chicago Admiistrative Stuff Lab1 out toight Due Thursday (10/18) Lab1 review sessio Tomorrow, 10/05,

More information

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated.

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated. 8-1 Name Binary code IDLE 000 Register operation or output R 0 RUN 0 1 Condition (a) State box (b) Example of state box (c) Decision box IDLE R 0 From decision box 0 1 START Register operation or output

More information

Module Instantiation. Finite State Machines. Two Types of FSMs. Finite State Machines. Given submodule mux32two: Instantiation of mux32two

Module Instantiation. Finite State Machines. Two Types of FSMs. Finite State Machines. Given submodule mux32two: Instantiation of mux32two Give submodule mux32two: 2-to- MUX module mux32two (iput [3:] i,i, iput sel, output [3:] out); Module Istatiatio Fiite Machies esig methodology for sequetial logic -- idetify distict s -- create trasitio

More information

Improvement of the Orthogonal Code Convolution Capabilities Using FPGA Implementation

Improvement of the Orthogonal Code Convolution Capabilities Using FPGA Implementation Improvemet of the Orthogoal Code Covolutio Capabilities Usig FPGA Implemetatio Naima Kaabouch, Member, IEEE, Apara Dhirde, Member, IEEE, Saleh Faruque, Member, IEEE Departmet of Electrical Egieerig, Uiversity

More information

Behavioral Modeling in Verilog

Behavioral Modeling in Verilog Behavioral Modelig i Verilog COE 202 Digital Logic Desig Dr. Muhamed Mudawar Kig Fahd Uiversity of Petroleum ad Mierals Presetatio Outlie Itroductio to Dataflow ad Behavioral Modelig Verilog Operators

More information

TABLE 8-1. Control Signals for Binary Multiplier. Load. MUL0 Q 0 CAQ sr CAQ. Shift_dec. C out. Load LOADQ. CAQ sr CAQ. Shift_dec P P 1.

TABLE 8-1. Control Signals for Binary Multiplier. Load. MUL0 Q 0 CAQ sr CAQ. Shift_dec. C out. Load LOADQ. CAQ sr CAQ. Shift_dec P P 1. T-192 Control Signals for Binary Multiplier TABLE 8-1 Control Signals for Binary Multiplier Block Diagram Module Microoperation Control Signal Name Control Expression Register A: A 0 Initialize IDLE G

More information

EE260: Digital Design, Spring /16/18. n Example: m 0 (=x 1 x 2 ) is adjacent to m 1 (=x 1 x 2 ) and m 2 (=x 1 x 2 ) but NOT m 3 (=x 1 x 2 )

EE260: Digital Design, Spring /16/18. n Example: m 0 (=x 1 x 2 ) is adjacent to m 1 (=x 1 x 2 ) and m 2 (=x 1 x 2 ) but NOT m 3 (=x 1 x 2 ) EE26: Digital Desig, Sprig 28 3/6/8 EE 26: Itroductio to Digital Desig Combiatioal Datapath Yao Zheg Departmet of Electrical Egieerig Uiversity of Hawaiʻi at Māoa Combiatioal Logic Blocks Multiplexer Ecoders/Decoders

More information

APPLICATION NOTE PACE1750AE BUILT-IN FUNCTIONS

APPLICATION NOTE PACE1750AE BUILT-IN FUNCTIONS APPLICATION NOTE PACE175AE BUILT-IN UNCTIONS About This Note This applicatio brief is iteded to explai ad demostrate the use of the special fuctios that are built ito the PACE175AE processor. These powerful

More information

CMSC Computer Architecture Lecture 12: Virtual Memory. Prof. Yanjing Li University of Chicago

CMSC Computer Architecture Lecture 12: Virtual Memory. Prof. Yanjing Li University of Chicago CMSC 22200 Computer Architecture Lecture 12: Virtual Memory Prof. Yajig Li Uiversity of Chicago A System with Physical Memory Oly Examples: most Cray machies early PCs Memory early all embedded systems

More information

1. SWITCHING FUNDAMENTALS

1. SWITCHING FUNDAMENTALS . SWITCING FUNDMENTLS Switchig is the provisio of a o-demad coectio betwee two ed poits. Two distict switchig techiques are employed i commuicatio etwors-- circuit switchig ad pacet switchig. Circuit switchig

More information

L6: FSMs and Synchronization

L6: FSMs and Synchronization L6: FSMs ad Sychroizatio Ackowledgemets: Materials i this lecture are courtesy of the followig sources ad are used with permissio. Rex Mi J. Rabaey, A. Chadrakasa, B. Nikolic. igital Itegrated Circuits:

More information

Digital System Design

Digital System Design July, 22 9:55 vra235_ch Sheet umber Page umber 65 black chapter Digital System Desig a b c d e f g h 8 7 6 5 4 3 2. Bd3 g6+, Ke8 d8 65 July, 22 9:55 vra235_ch Sheet umber 2 Page umber 66 black 66 CHAPTER

More information

Lecture 1: Introduction and Fundamental Concepts 1

Lecture 1: Introduction and Fundamental Concepts 1 Uderstadig Performace Lecture : Fudametal Cocepts ad Performace Aalysis CENG 332 Algorithm Determies umber of operatios executed Programmig laguage, compiler, architecture Determie umber of machie istructios

More information

CMSC Computer Architecture Lecture 5: Pipelining. Prof. Yanjing Li University of Chicago

CMSC Computer Architecture Lecture 5: Pipelining. Prof. Yanjing Li University of Chicago CMSC 22200 Computer Architecture Lecture 5: Pipeliig Prof. Yajig Li Uiversity of Chicago Admiistrative Stuff Lab1 Due toight Lab2: out later today; due 2 weeks from ow Review sessio this Friday Turig award

More information

COMPUTER ORGANIZATION AND DESIGN

COMPUTER ORGANIZATION AND DESIGN COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Review Istructio Set Architecture Istructio Set The repertoire of istructios of a computer Differet computers have differet istructio

More information

Arquitectura de Computadores

Arquitectura de Computadores Arquitectura de Computadores Capítulo 2. Procesadores segmetados Based o the origial material of the book: D.A. Patterso y J.L. Heessy Computer Orgaizatio ad Desig: The Hardware/Software Iterface 4 th

More information

Basic allocator mechanisms The course that gives CMU its Zip! Memory Management II: Dynamic Storage Allocation Mar 6, 2000.

Basic allocator mechanisms The course that gives CMU its Zip! Memory Management II: Dynamic Storage Allocation Mar 6, 2000. 5-23 The course that gives CM its Zip Memory Maagemet II: Dyamic Storage Allocatio Mar 6, 2000 Topics Segregated lists Buddy system Garbage collectio Mark ad Sweep Copyig eferece coutig Basic allocator

More information

Chapter 3. Floating Point Arithmetic

Chapter 3. Floating Point Arithmetic COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 3 Floatig Poit Arithmetic Review - Multiplicatio 0 1 1 0 = 6 multiplicad 32-bit ALU shift product right multiplier add

More information

Custom single-purpose processors: Hardware. 4.1 Introduction. 4.2 Combinational logic design 4-1

Custom single-purpose processors: Hardware. 4.1 Introduction. 4.2 Combinational logic design 4-1 Chapter 4: Custom sigle-purpose processors: Hardware 4- Chapter 4 Custom sigle-purpose processors: Hardware 4. Itroductio As metioed i the previous chapter, a sigle-purpose processor is a digital sstem

More information

Computers and Scientific Thinking

Computers and Scientific Thinking Computers ad Scietific Thikig David Reed, Creighto Uiversity Chapter 15 JavaScript Strigs 1 Strigs as Objects so far, your iteractive Web pages have maipulated strigs i simple ways use text box to iput

More information

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor Advanced Issues

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor Advanced Issues COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 4 The Processor Advaced Issues Review: Pipelie Hazards Structural hazards Desig pipelie to elimiate structural hazards.

More information

Computer Systems - HS

Computer Systems - HS What have we leared so far? Computer Systems High Level ENGG1203 2d Semester, 2017-18 Applicatios Sigals Systems & Cotrol Systems Computer & Embedded Systems Digital Logic Combiatioal Logic Sequetial Logic

More information

Chapter 3 Classification of FFT Processor Algorithms

Chapter 3 Classification of FFT Processor Algorithms Chapter Classificatio of FFT Processor Algorithms The computatioal complexity of the Discrete Fourier trasform (DFT) is very high. It requires () 2 complex multiplicatios ad () complex additios [5]. As

More information

Fundamentals of. Chapter 1. Microprocessor and Microcontroller. Dr. Farid Farahmand. Updated: Tuesday, January 16, 2018

Fundamentals of. Chapter 1. Microprocessor and Microcontroller. Dr. Farid Farahmand. Updated: Tuesday, January 16, 2018 Fudametals of Chapter 1 Microprocessor ad Microcotroller Dr. Farid Farahmad Updated: Tuesday, Jauary 16, 2018 Evolutio First came trasistors Itegrated circuits SSI (Small-Scale Itegratio) to ULSI Very

More information

A collection of open-sourced RISC-V processors

A collection of open-sourced RISC-V processors Riscy Processors A collectio of ope-sourced RISC-V processors Ady Wright, Sizhuo Zhag, Thomas Bourgeat, Murali Vijayaraghava, Jamey Hicks, Arvid Computatio Structures Group, CSAIL, MIT 4 th RISC-V Workshop

More information

Data Structures and Algorithms. Analysis of Algorithms

Data Structures and Algorithms. Analysis of Algorithms Data Structures ad Algorithms Aalysis of Algorithms Outlie Ruig time Pseudo-code Big-oh otatio Big-theta otatio Big-omega otatio Asymptotic algorithm aalysis Aalysis of Algorithms Iput Algorithm Output

More information

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe CHAPTER 19 Query Optimizatio Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe Itroductio Query optimizatio Coducted by a query optimizer i a DBMS Goal:

More information

Lecture 1: Introduction and Strassen s Algorithm

Lecture 1: Introduction and Strassen s Algorithm 5-750: Graduate Algorithms Jauary 7, 08 Lecture : Itroductio ad Strasse s Algorithm Lecturer: Gary Miller Scribe: Robert Parker Itroductio Machie models I this class, we will primarily use the Radom Access

More information

Course Site: Copyright 2012, Elsevier Inc. All rights reserved.

Course Site:   Copyright 2012, Elsevier Inc. All rights reserved. Course Site: http://cc.sjtu.edu.c/g2s/site/aca.html 1 Computer Architecture A Quatitative Approach, Fifth Editio Chapter 2 Memory Hierarchy Desig 2 Outlie Memory Hierarchy Cache Desig Basic Cache Optimizatios

More information

Lower Bounds for Sorting

Lower Bounds for Sorting Liear Sortig Topics Covered: Lower Bouds for Sortig Coutig Sort Radix Sort Bucket Sort Lower Bouds for Sortig Compariso vs. o-compariso sortig Decisio tree model Worst case lower boud Compariso Sortig

More information

Running Time. Analysis of Algorithms. Experimental Studies. Limitations of Experiments

Running Time. Analysis of Algorithms. Experimental Studies. Limitations of Experiments Ruig Time Aalysis of Algorithms Iput Algorithm Output A algorithm is a step-by-step procedure for solvig a problem i a fiite amout of time. Most algorithms trasform iput objects ito output objects. The

More information

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe CHAPTER 18 Strategies for Query Processig Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe Itroductio DBMS techiques to process a query Scaer idetifies

More information

Running Time ( 3.1) Analysis of Algorithms. Experimental Studies. Limitations of Experiments

Running Time ( 3.1) Analysis of Algorithms. Experimental Studies. Limitations of Experiments Ruig Time ( 3.1) Aalysis of Algorithms Iput Algorithm Output A algorithm is a step- by- step procedure for solvig a problem i a fiite amout of time. Most algorithms trasform iput objects ito output objects.

More information

Analysis of Algorithms

Analysis of Algorithms Aalysis of Algorithms Iput Algorithm Output A algorithm is a step-by-step procedure for solvig a problem i a fiite amout of time. Ruig Time Most algorithms trasform iput objects ito output objects. The

More information

Data diverse software fault tolerance techniques

Data diverse software fault tolerance techniques Data diverse software fault tolerace techiques Complemets desig diversity by compesatig for desig diversity s s limitatios Ivolves obtaiig a related set of poits i the program data space, executig the

More information

CIS 121 Data Structures and Algorithms with Java Spring Stacks, Queues, and Heaps Monday, February 18 / Tuesday, February 19

CIS 121 Data Structures and Algorithms with Java Spring Stacks, Queues, and Heaps Monday, February 18 / Tuesday, February 19 CIS Data Structures ad Algorithms with Java Sprig 09 Stacks, Queues, ad Heaps Moday, February 8 / Tuesday, February 9 Stacks ad Queues Recall the stack ad queue ADTs (abstract data types from lecture.

More information

Sorting in Linear Time. Data Structures and Algorithms Andrei Bulatov

Sorting in Linear Time. Data Structures and Algorithms Andrei Bulatov Sortig i Liear Time Data Structures ad Algorithms Adrei Bulatov Algorithms Sortig i Liear Time 7-2 Compariso Sorts The oly test that all the algorithms we have cosidered so far is compariso The oly iformatio

More information

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Determined by ISA and compiler. Determined by CPU hardware

COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 4. The Processor. Determined by ISA and compiler. Determined by CPU hardware COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface ARM Editio Chapter 4 The Processor Itroductio CPU performace factors Istructio cout Determied by ISA ad compiler CPI ad Cycle time Determied

More information

Chapter 1. Introduction to Computers and C++ Programming. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 1. Introduction to Computers and C++ Programming. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 1 Itroductio to Computers ad C++ Programmig Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 1.1 Computer Systems 1.2 Programmig ad Problem Solvig 1.3 Itroductio to C++ 1.4 Testig

More information

CS252 Spring 2017 Graduate Computer Architecture. Lecture 6: Out-of-Order Processors

CS252 Spring 2017 Graduate Computer Architecture. Lecture 6: Out-of-Order Processors CS252 Sprig 2017 Graduate Computer Architecture Lecture 6: Out-of-Order Processors Lisa Wu, Krste Asaovic http://ist.eecs.berkeley.edu/~cs252/sp17 WU UCB CS252 SP17 2 WU UCB CS252 SP17 Last Time i Lecture

More information

Pseudocode ( 1.1) Analysis of Algorithms. Primitive Operations. Pseudocode Details. Running Time ( 1.1) Estimating performance

Pseudocode ( 1.1) Analysis of Algorithms. Primitive Operations. Pseudocode Details. Running Time ( 1.1) Estimating performance Aalysis of Algorithms Iput Algorithm Output A algorithm is a step-by-step procedure for solvig a problem i a fiite amout of time. Pseudocode ( 1.1) High-level descriptio of a algorithm More structured

More information

Chapter 10. Defining Classes. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 10. Defining Classes. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 10 Defiig Classes Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 10.1 Structures 10.2 Classes 10.3 Abstract Data Types 10.4 Itroductio to Iheritace Copyright 2015 Pearso Educatio,

More information

Chapter 11. Friends, Overloaded Operators, and Arrays in Classes. Copyright 2014 Pearson Addison-Wesley. All rights reserved.

Chapter 11. Friends, Overloaded Operators, and Arrays in Classes. Copyright 2014 Pearson Addison-Wesley. All rights reserved. Chapter 11 Frieds, Overloaded Operators, ad Arrays i Classes Copyright 2014 Pearso Addiso-Wesley. All rights reserved. Overview 11.1 Fried Fuctios 11.2 Overloadig Operators 11.3 Arrays ad Classes 11.4

More information

How do we evaluate algorithms?

How do we evaluate algorithms? F2 Readig referece: chapter 2 + slides Algorithm complexity Big O ad big Ω To calculate ruig time Aalysis of recursive Algorithms Next time: Litterature: slides mostly The first Algorithm desig methods:

More information

top() Applications of Stacks

top() Applications of Stacks CS22 Algorithms ad Data Structures MW :00 am - 2: pm, MSEC 0 Istructor: Xiao Qi Lecture 6: Stacks ad Queues Aoucemets Quiz results Homework 2 is available Due o September 29 th, 2004 www.cs.mt.edu~xqicoursescs22

More information

K-NET bus. When several turrets are connected to the K-Bus, the structure of the system is as showns

K-NET bus. When several turrets are connected to the K-Bus, the structure of the system is as showns K-NET bus The K-Net bus is based o the SPI bus but it allows to addressig may differet turrets like the I 2 C bus. The K-Net is 6 a wires bus (4 for SPI wires ad 2 additioal wires for request ad ackowledge

More information

UNIVERSITY OF MORATUWA

UNIVERSITY OF MORATUWA UNIVERSITY OF MORATUWA FACULTY OF ENGINEERING DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING B.Sc. Egieerig 2014 Itake Semester 2 Examiatio CS2052 COMPUTER ARCHITECTURE Time allowed: 2 Hours Jauary 2016

More information

Heaps. Presentation for use with the textbook Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, 2015

Heaps. Presentation for use with the textbook Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, 2015 Presetatio for use with the textbook Algorithm Desig ad Applicatios, by M. T. Goodrich ad R. Tamassia, Wiley, 201 Heaps 201 Goodrich ad Tamassia xkcd. http://xkcd.com/83/. Tree. Used with permissio uder

More information

Python Programming: An Introduction to Computer Science

Python Programming: An Introduction to Computer Science Pytho Programmig: A Itroductio to Computer Sciece Chapter 6 Defiig Fuctios Pytho Programmig, 2/e 1 Objectives To uderstad why programmers divide programs up ito sets of cooperatig fuctios. To be able to

More information

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5 Morga Kaufma Publishers 26 February, 28 COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 5 Set-Associative Cache Architecture Performace Summary Whe CPU performace icreases:

More information

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe CHAPTER 22 Database Recovery Techiques Copyright 2016 Ramez Elmasri ad Shamkat B. Navathe Itroductio Recovery algorithms Recovery cocepts Write-ahead

More information

DESIGN AND ANALYSIS OF LDPC DECODERS FOR SOFTWARE DEFINED RADIO

DESIGN AND ANALYSIS OF LDPC DECODERS FOR SOFTWARE DEFINED RADIO DESIGN AND ANALYSIS OF LDPC DECODERS FOR SOFTWARE DEFINED RADIO Sagwo Seo, Trevor Mudge Advaced Computer Architecture Laboratory Uiversity of Michiga at A Arbor {swseo, tm}@umich.edu Yumig Zhu, Chaitali

More information

Analysis Metrics. Intro to Algorithm Analysis. Slides. 12. Alg Analysis. 12. Alg Analysis

Analysis Metrics. Intro to Algorithm Analysis. Slides. 12. Alg Analysis. 12. Alg Analysis Itro to Algorithm Aalysis Aalysis Metrics Slides. Table of Cotets. Aalysis Metrics 3. Exact Aalysis Rules 4. Simple Summatio 5. Summatio Formulas 6. Order of Magitude 7. Big-O otatio 8. Big-O Theorems

More information

Algorithm. Counting Sort Analysis of Algorithms

Algorithm. Counting Sort Analysis of Algorithms Algorithm Coutig Sort Aalysis of Algorithms Assumptios: records Coutig sort Each record cotais keys ad data All keys are i the rage of 1 to k Space The usorted list is stored i A, the sorted list will

More information

Lecture 11: PI/T parallel I/O, part I

Lecture 11: PI/T parallel I/O, part I Lecture 11: PI/T parallel I/O, part I Geeral descriptio of the parallel I/O fuctio Bufferi Hadshaki Iput ad Output trasfers Timi Diarams Reister model of the 68230 Port Geeral Cotrol Reister (PGCR) Port

More information

Master Informatics Eng. 2017/18. A.J.Proença. Memory Hierarchy. (most slides are borrowed) AJProença, Advanced Architectures, MiEI, UMinho, 2017/18 1

Master Informatics Eng. 2017/18. A.J.Proença. Memory Hierarchy. (most slides are borrowed) AJProença, Advanced Architectures, MiEI, UMinho, 2017/18 1 Advaced Architectures Master Iformatics Eg. 2017/18 A.J.Proeça Memory Hierarchy (most slides are borrowed) AJProeça, Advaced Architectures, MiEI, UMiho, 2017/18 1 Itroductio Programmers wat ulimited amouts

More information

CMSC22200 Computer Architecture Lecture 9: Out-of-Order, SIMD, VLIW. Prof. Yanjing Li University of Chicago

CMSC22200 Computer Architecture Lecture 9: Out-of-Order, SIMD, VLIW. Prof. Yanjing Li University of Chicago CMSC22200 Computer Architecture Lecture 9: Out-of-Order, SIMD, VLIW Prof. Yajig Li Uiversity of Chicago Admiistrative Stuff Lab2 due toight Exam I: covers lectures 1-9 Ope book, ope otes, close device

More information

Lecture 5. Counting Sort / Radix Sort

Lecture 5. Counting Sort / Radix Sort Lecture 5. Coutig Sort / Radix Sort T. H. Corme, C. E. Leiserso ad R. L. Rivest Itroductio to Algorithms, 3rd Editio, MIT Press, 2009 Sugkyukwa Uiversity Hyuseug Choo choo@skku.edu Copyright 2000-2018

More information

EE University of Minnesota. Midterm Exam #1. Prof. Matthew O'Keefe TA: Eric Seppanen. Department of Electrical and Computer Engineering

EE University of Minnesota. Midterm Exam #1. Prof. Matthew O'Keefe TA: Eric Seppanen. Department of Electrical and Computer Engineering EE 4363 1 Uiversity of Miesota Midterm Exam #1 Prof. Matthew O'Keefe TA: Eric Seppae Departmet of Electrical ad Computer Egieerig Uiversity of Miesota Twi Cities Campus EE 4363 Itroductio to Microprocessors

More information

Outline and Reading. Analysis of Algorithms. Running Time. Experimental Studies. Limitations of Experiments. Theoretical Analysis

Outline and Reading. Analysis of Algorithms. Running Time. Experimental Studies. Limitations of Experiments. Theoretical Analysis Outlie ad Readig Aalysis of Algorithms Iput Algorithm Output Ruig time ( 3.) Pseudo-code ( 3.2) Coutig primitive operatios ( 3.3-3.) Asymptotic otatio ( 3.6) Asymptotic aalysis ( 3.7) Case study Aalysis

More information

6.175: Constructive Computer Architecture. Oct 7,

6.175: Constructive Computer Architecture. Oct 7, 6.175: Costructive Computer Architecture Tutorial 2 Advaced BSV Qua Nguye (Now uses the correct dates o PPT slides) T02-1 Admiistrivia Today is add date! Please test vlsifarm machies Remaiig labs schedule

More information

Instruction and Data Streams

Instruction and Data Streams Advaced Architectures Master Iformatics Eg. 2017/18 A.J.Proeça Data Parallelism 1 (vector & SIMD extesios) (most slides are borrowed) AJProeça, Advaced Architectures, MiEI, UMiho, 2017/18 1 Istructio ad

More information

Chapter 9. Pointers and Dynamic Arrays. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 9. Pointers and Dynamic Arrays. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 9 Poiters ad Dyamic Arrays Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 9.1 Poiters 9.2 Dyamic Arrays Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Slide 9-3

More information

Reversible Realization of Quaternary Decoder, Multiplexer, and Demultiplexer Circuits

Reversible Realization of Quaternary Decoder, Multiplexer, and Demultiplexer Circuits Egieerig Letters, :, EL Reversible Realizatio of Quaterary Decoder, Multiplexer, ad Demultiplexer Circuits Mozammel H.. Kha, Member, ENG bstract quaterary reversible circuit is more compact tha the correspodig

More information

Introduction CHAPTER Computers

Introduction CHAPTER Computers Iside a Computer CHAPTER Itroductio. Computers A computer is a electroic device that accepts iput, stores data, processes data accordig to a set of istructios (called program), ad produces output i desired

More information

Bezier curves. Figure 2 shows cubic Bezier curves for various control points. In a Bezier curve, only

Bezier curves. Figure 2 shows cubic Bezier curves for various control points. In a Bezier curve, only Edited: Yeh-Liag Hsu (998--; recommeded: Yeh-Liag Hsu (--9; last updated: Yeh-Liag Hsu (9--7. Note: This is the course material for ME55 Geometric modelig ad computer graphics, Yua Ze Uiversity. art of

More information

CMSC Computer Architecture Lecture 10: Caches. Prof. Yanjing Li University of Chicago

CMSC Computer Architecture Lecture 10: Caches. Prof. Yanjing Li University of Chicago CMSC 22200 Computer Architecture Lecture 10: Caches Prof. Yajig Li Uiversity of Chicago Midterm Recap Overview ad fudametal cocepts ISA Uarch Datapath, cotrol Sigle cycle, multi cycle Pipeliig Basic idea,

More information

Chapter 5. Functions for All Subtasks. Copyright 2015 Pearson Education, Ltd.. All rights reserved.

Chapter 5. Functions for All Subtasks. Copyright 2015 Pearson Education, Ltd.. All rights reserved. Chapter 5 Fuctios for All Subtasks Copyright 2015 Pearso Educatio, Ltd.. All rights reserved. Overview 5.1 void Fuctios 5.2 Call-By-Referece Parameters 5.3 Usig Procedural Abstractio 5.4 Testig ad Debuggig

More information

Bluespec-3: Modules & Interfaces. Bluespec: State and Rules organized into modules

Bluespec-3: Modules & Interfaces. Bluespec: State and Rules organized into modules Bluespec-3: Modules & Iterfaces Arvid Computer Sciece & Artificial Itelligece Lab Massachusetts Istitute of Techology Based o material prepared by Bluespec Ic, Jauary 2005 February 28, 2005 L09-1 Bluespec:

More information

1 Enterprise Modeler

1 Enterprise Modeler 1 Eterprise Modeler Itroductio I BaaERP, a Busiess Cotrol Model ad a Eterprise Structure Model for multi-site cofiguratios are itroduced. Eterprise Structure Model Busiess Cotrol Models Busiess Fuctio

More information

Τεχνολογία Λογισμικού

Τεχνολογία Λογισμικού ΕΘΝΙΚΟ ΜΕΤΣΟΒΙΟ ΠΟΛΥΤΕΧΝΕΙΟ Σχολή Ηλεκτρολόγων Μηχανικών και Μηχανικών Υπολογιστών Τεχνολογία Λογισμικού, 7ο/9ο εξάμηνο 2018-2019 Τεχνολογία Λογισμικού Ν.Παπασπύρου, Αν.Καθ. ΣΗΜΜΥ, ickie@softlab.tua,gr

More information

6.854J / J Advanced Algorithms Fall 2008

6.854J / J Advanced Algorithms Fall 2008 MIT OpeCourseWare http://ocw.mit.edu 6.854J / 18.415J Advaced Algorithms Fall 2008 For iformatio about citig these materials or our Terms of Use, visit: http://ocw.mit.edu/terms. 18.415/6.854 Advaced Algorithms

More information

% Sun Logo for. X3T10/95-229, Revision 0. April 18, 1998

% Sun Logo for. X3T10/95-229, Revision 0. April 18, 1998 Su Microsystems, Ic. 2550 Garcia Aveue Moutai View, CA 94045 415 960-1300 X3T10/95-229, Revisio 0 April 18, 1998 % Su Logo for Joh Lohmeyer Chairperso, X3T10 Symbios Logic Ic. 1635 Aeroplaza Drive Colorado

More information

Threads and Concurrency in Java: Part 1

Threads and Concurrency in Java: Part 1 Cocurrecy Threads ad Cocurrecy i Java: Part 1 What every computer egieer eeds to kow about cocurrecy: Cocurrecy is to utraied programmers as matches are to small childre. It is all too easy to get bured.

More information

Threads and Concurrency in Java: Part 1

Threads and Concurrency in Java: Part 1 Threads ad Cocurrecy i Java: Part 1 1 Cocurrecy What every computer egieer eeds to kow about cocurrecy: Cocurrecy is to utraied programmers as matches are to small childre. It is all too easy to get bured.

More information

The Magma Database file formats

The Magma Database file formats The Magma Database file formats Adrew Gaylard, Bret Pikey, ad Mart-Mari Breedt Johaesburg, South Africa 15th May 2006 1 Summary Magma is a ope-source object database created by Chris Muller, of Kasas City,

More information

% Sun Logo for Frame. X3T10/95-229, Revision 2. September 28, 1995

% Sun Logo for Frame. X3T10/95-229, Revision 2. September 28, 1995 Su Microsystems, Ic. 2550 Garcia Aveue Moutai View, CA 94045 415 960-1300 X3T10/95-229, Revisio 2 September 28, 1995 % Su Logo for Frame Joh Lohmeyer Chairperso, X3T10 Symbios Logic Ic. 1635 Aeroplaza

More information

Structuring Redundancy for Fault Tolerance. CSE 598D: Fault Tolerant Software

Structuring Redundancy for Fault Tolerance. CSE 598D: Fault Tolerant Software Structurig Redudacy for Fault Tolerace CSE 598D: Fault Tolerat Software What do we wat to achieve? Versios Damage Assessmet Versio 1 Error Detectio Iputs Versio 2 Voter Outputs State Restoratio Cotiued

More information

Chapter 4 Threads. Operating Systems: Internals and Design Principles. Ninth Edition By William Stallings

Chapter 4 Threads. Operating Systems: Internals and Design Principles. Ninth Edition By William Stallings Operatig Systems: Iterals ad Desig Priciples Chapter 4 Threads Nith Editio By William Stalligs Processes ad Threads Resource Owership Process icludes a virtual address space to hold the process image The

More information

8.0 Resolving Multi-Signal Drivers

8.0 Resolving Multi-Signal Drivers Fileame= ch8_2 8.0 Resolvig Multi-Sigal Drivers 8.1 Buses B ACTL BCTL DBUS DBUS A DBUS Ope circle deotes a iput coectio Solid dot deotes a output coectio The ope circles at the bus iputs respreset switched

More information

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5.

Morgan Kaufmann Publishers 26 February, COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface. Chapter 5. Morga Kaufma Publishers 26 February, 208 COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Iterface 5 th Editio Chapter 5 Virtual Memory Review: The Memory Hierarchy Take advatage of the priciple

More information

Software development of components for complex signal analysis on the example of adaptive recursive estimation methods.

Software development of components for complex signal analysis on the example of adaptive recursive estimation methods. Software developmet of compoets for complex sigal aalysis o the example of adaptive recursive estimatio methods. SIMON BOYMANN, RALPH MASCHOTTA, SILKE LEHMANN, DUNJA STEUER Istitute of Biomedical Egieerig

More information