234262 Tutorials #4-#5 Controller + DataPath design 234262 – © Yohai Devir 2007 Technion - IIT.

Slides:



Advertisements
Similar presentations
תרשים מצבים - התהליכים P2: wait(S); signal(S); Q; P1: signal(S); wait(S); A;
Advertisements

– © Yohai Devir 2007 Technion - IIT Tutorial #10 MIPS commands.
Computing Machinery Chapter 7: Register Transfers.
Repetition Control Structures School of Business Eastern Illinois University © Abdou Illia, Spring 2003 (Week 9, Friday 3/07/2003)
מבוסס על הרצאות של יורם זינגר, האוניברסיטה העברית י"ם
CS 151 Digital Systems Design Lecture 37 Register Transfer Level
שאלת חזרה בקר ומסלול נתונים – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
Tutorial #10 MIPS commands – © Yohai Devir 2007 Technion - IIT.
CS Fall 2005 – Lec #16 – Retiming - 1 State Machine Timing zRetiming ySlosh logic between registers to balance latencies and improve clock timings.
משטר דינמי המשך – © Dima Elenbogen :55 חידה שכדאי לעבור עליה: 2011/ho/WCFiles/%D7%97%D7%99%D7%93%D7%94%20%D7%A2%D7%9D%20%D7%91%D7%95%D7%A0%D7%95%D7%A1.doc.
Tutorial #13 Solving MIPS Exam Problems 20: © Dima Elenbogen 2010, Technion 1.
CS 140 Lecture 16 System Designs Professor CK Cheng CSE Dept. UC San Diego 1.
שערים לוגיים – © Dima Elenbogen Wired AND – © Dima Elenbogen 2009.
Tutorial #7 Preventing combinatorial loops – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
– © Dima Elenbogen :43 להזכירכם ספיקה (Throughput)כמה חישובים מסוגלת המערכת לבצע ביחידת זמן. עיכוב (Latency)פרק הזמן העובר מהרגע שבו התקבל.
מבוא למדעי המחשב © אריק פרידמן 1 מצביעים כמערכים דוגמה.
תירגול השלמה : Pipelined MIPS Single-cycle MIPS Retiming Mealy Criterion 09: © Dima Elenbogen 2010, Technion 1.
משטר דינמי – © Dima Elenbogen :00. הגדרת cd ו -pd cd - הזמן שעובר בין הרגע שראשון אותות הכניסה יוצא מתחום לוגי עד אשר אות המוצא יוצא מתחום.
CS 140 Lecture 18 Professor CK Cheng 6/04/02. Part IV. System Designs Algorithm: { Input X, Y type bit-vector, start type boolean; Local-Object A, B type.
שערים לוגיים – © Dima Elenbogen Wired AND – © Dima Elenbogen 2009.
Solving MIPS Exam Problems 21: © Dima Elenbogen 2010, Technion 1.
Tutorial #6 Controller + DataPath part II – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
Give qualifications of instructors: DAP
– © Dima Elenbogen :11 להזכירכם ספיקה (Throughput)כמה חישובים מסוגלת המערכת לבצע ביחידת זמן. עיכוב (Latency)פרק הזמן העובר מהרגע שבו התקבל.
Tutorial #7 Preventing combinatorial loops – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
שערים לוגיים – © Dima Elenbogen Wired AND – © Dima Elenbogen 2009.
Tutorial #13 Solving MIPS Exam Problems 01: © Dima Elenbogen 2010, Technion 1.
– © Yohai Devir 2007 Technion - IIT Tutorial #6 Controller + DataPath part II.
CS 140L Lecture 7 Professor CK Cheng 11/12/02. Transformation between Mealy and Moore Machines Algorithm: 1) For each NS, z = S i, j create a state S.
משטר דינמי – © Dima Elenbogen :14. הגדרת cd ו -pd cd - הזמן שעובר בין הרגע שראשון אותות הכניסה יוצא מתחום לוגי עד אשר אות המוצא יוצא מתחום.
– © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT Tutorial #7 Preventing combinatorial loops.
מבוא למדעי המחשב, סמסטר א ', תשע " א תרגול מס ' 1 נושאים  הכרת הקורס  פסאודו - קוד / אלגוריתם 1.
משטר סטטי שערים לוגיים – © Dima Elenbogen 2009, Moshe Malka :59.
שאלה 9 – בקר ומסלול - נתונים נתונה המערכת הבאה של בקר ומסלול נתונים. כל הקווים העבים בשרטוט ה DP הם ברוחב n. ה -ADDER מחבר מודולו n 2. COMPARE הוא רכיב.
Tutorial #6 Controller + DataPath part II – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
Tutorial #6 Controller + DataPath part II – © Yohai Devir 2007 © Dima Elenbogen 2009 Technion - IIT.
9/15/09 - L25 Registers & Load Enable Copyright Joanne DeGroat, ECE, OSU1 Registers & Load Enable.
Unit 4 Design and Synthesis of Datapath Controllers
Algorithmic State Machines.  1) Create an algorithm, using pseudocode, to describe the desired operation of the device. 2) Convert the pseudocode into.
Modern VLSI Design 4e: Chapter 8 Copyright  2008 Wayne Wolf Topics Basics of register-transfer design: –data paths and controllers; –ASM charts. Pipelining.
Unit 13 Analysis of Clocked Sequential Circuits Ku-Yaw Chang Assistant Professor, Department of Computer Science and Information.
Practice session 3.  תחביר ממשי ( קונקרטי ) ותחביר מופשט ( אבסטרקטי )  שיטות חישוב : Applicative & Normal Evaluation.
Lecture 9 RTL Design Methodology. Structure of a Typical Digital System Datapath (Execution Unit) Controller (Control Unit) Data Inputs Data Outputs Control.
Finite state machines Modelling FSM in VHDL. Types of automata (FSM) A sequential automaton has: –Inputs –States (a finite number of states) –Outputs.
Registers; State Machines Analysis Section 7-1 Section 5-4.
University of Texas at Austin CS310 - Computer Organization Spring 2009 Don Fussell State Machines.
Modern VLSI Design 3e: Chapter 8 Copyright  1998, 2002 Prentice Hall PTR Topics n Basics of register-transfer design: –data paths and controllers; –ASM.
1 Programming for Engineers in Python Autumn Lecture 9: Sorting, Searching and Time Complexity Analysis.
1 ECE 545 – Introduction to VHDL Algorithmic State Machines Sorting Example ECE 656 Lecture 8.
The LC-3 – Chapter 5 COMP 2620 Dr. James Money COMP
6.
CS Spring 2008 – Lec #17 – Retiming - 1
Carry Look Ahead (CLA).
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
RTL Design Methodology
Solving MIPS Exam Problems
Tutorial #10 MIPS commands
תרגול 6 בקר ומסלול נתונים חלק שני
Manual Example How to manually convert high-level code into circuit
תרגול 6 בקר ומסלול נתונים חלק שני
الفصل الثاني الخوارزمية
A register design with parallel load input
Register-Transfer Level Components in Verilog
Controllers and Datapaths
RTL Design Methodology
RTL Design Methodology
Lecture 17 State Machine Design Using SM Chart
Finite state machines Modelling FSM in VHDL.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Tutorials #4-#5 Coltroller + dataPath design
Presentation transcript:

Tutorials #4-#5 Controller + DataPath design – © Yohai Devir 2007 Technion - IIT

Controller & DP DP = מסלול נתונים זיכרון כלים (לוגיקה צירופית) נתב Controller = בקר "מוח המערכת" פלט קלט אותות בקרה אותות סטטוס – © Dima Elenbogen :54 פלט

Register רגיסטר = מערך של FF DQ רגיסטר לא מותנה DQ רגיסטר מותנה load – © Dima Elenbogen :54

Computing N! #1 – pseudo-Code i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); – © Yohai Devir 2007 Technion - IIT

Computing N! (2) #1 – pseudo-Code i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); i = N; result = 1; LOOP:if (i ≤ 1) goto END; result = result * i; i = i - 1; goto LOOP; END:done = 1; output(result); © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

Computing N! (3) #2 – finding variables i = N; result = 1; while (i > 1){ result = result * i; i = i - 1; } done = 1; output(result); © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

Computing N! (4) #3 – operations i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 GR

Computing N! (8) The Datapath i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_resld_i sel_isel_res GR out

ld_resld_i sel_isel_res GR out Computing N! (9) Datapath Flow Chart – what operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

Computing N! (10) Datapath Flow Chart – what operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = 1 (1) (i – 1) > 0 ? © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 Yes No

Computing N! (11) Datapath Flow Chart – which operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = 1 (1) (i – 1) > 0 ? (2) result = result * i (3) i = i © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 Yes No

Computing N! (12) Datapath Flow Chart – which operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = 1 (1) (i – 1) > 0 ? ניתן למזג © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 (2) result = result * i (3) i = i - 1 Yes No

Computing N! (13) Datapath Flow Chart – which operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = 1 (1) (i – 1) > 0? (2) result=result*i i = i © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 Yes No

Computing N! (14) Datapath Flow Chart – which operations can be done in parallel ? i = N; result = 1; while (i > 1) { result = result * i; i = i - 1; } done = 1; output(result); (0) i = N result = 1 (1) (i – 1) > 0? (2) result=result*i i = i © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 האם ניתן להפוך את סדר השורות? Yes No

Off the Record (1) אילו ע''פי האלגוריתם סדר השורות בגוף הלולאה היה במקור הפוך, האם עדיין היינו יכולים לבצע את גוף הלולאה במחזור יחיד? © Dima Elenbogen 2010 Technion - IIT... while (i > 1) { i = i - 1; result = result * i; }... ld_resld_i sel_isel_res GR out

... while (i > 1) { i = i - 1; result = result * i; }... אילו ע''פי האלגוריתם סדר השורות בגוף הלולאה היה במקור הפוך, האם עדיין היינו יכולים לבצע את גוף הלולאה במחזור יחיד? לא אם אסור לשנות את מסלול הנתונים © Dima Elenbogen 2010 Technion - IIT Off the Record (2) ld_resld_i sel_isel_res GR out

... while (i > 1) { i = i - 1; result = result * i; }... אילו ע''פי האלגוריתם סדר השורות בגוף הלולאה היה במקור הפוך, האם עדיין היינו יכולים לבצע את גוף הלולאה במחזור יחיד? כן אם מותר לשנות את מסלול הנתונים ולהזין את הערך החדש של i ישירות מהמחסר © Dima Elenbogen 2010 Technion - IIT Off the Record (3) ld_resld_i sel_isel_res GR out

Computing N! (15) בקר – תרשים זרימה (0) i = N result = 1 (1) (i – 1) > 0? (2) result=result*i i = i - 1 (3) Yes No (0) (1) (2) (3) © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

? Computing N! (16) בקר – דיאגרמת מצבים (0) i = N result = 1 (1) (i – 1) > 0 ? (2) result=result*i i = i - 1 (3) Yes No ld_i, ld_res sel_res = 0 sel_i = 0 ? ? ? © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

Computing N! (17) (0) i = N result = 1 (1) (i – 1) > 0 ? (2) result=result*i i = i - 1 (3) © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_i, ld_res sel_res = 0 sel_i = 0 ? ? gr בקר – דיאגרמת מצבים Yes No

Computing N! (18) (0) i = N result = 1 (1) (i – 1) > 0 ? (2) result=result*i i = i - 1 (3) © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 ? gr בקר – דיאגרמת מצבים Yes No

Computing N! (19) בקר – דיאגרמת מצבים (0) i = N result = 1 (1) (i – 1) > 0 ? (2) result=result*i i = i - 1 (3) © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 done gr Yes No

Computing N! (20) מהו סוג הבקר?  Mealy  Moore © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 done gr

Computing N! (20) מהו סוג הבקר?  Mealy Moore ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 done © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 gr

Computing N! (21) בקר – מימוש ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 done © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 gr

Computing N! (22) בקר – מימוש CS Sel_iLoad_iSel_resLoad_resDone © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 ld_i, ld_res sel_res = 0 sel_i = 0 ld_i ld_res sel_res = 1 sel_i = 1 done gr

© Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009 Computing N! (23) CONTROL + DP External Clock

Computing N! (24) © Yohai Devir 2007 Technion - IIT© Dima Elenbogen 2009

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13?? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13?? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  i=1? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? 3Ø res  i*res i  i CS Sel_iLoad_iSel_resLoad_resDone

DP signalsControl signals Comment Niresi-1i*resGRCSNSsel i sel res load i load res done 13????? i  N; res  1 2Ø i=1? 3Ø res  i*res i  i-1 4Ø i=1? 5Ø res  i*res i  i-1 6Ø i=1? 7Ø done 8Ø done CS Sel_iLoad_iSel_resLoad_resDone

– © Yohai Devir 2007 Technion - IIT Another example

– © Yohai Devir 2007 Technion - IIT 2 nd example - hardware i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT 2 nd example - hardware i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT 2 nd example - hardware i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT i = N; K = 2; while (i / K >= K) { If (i % K == 0) { i = i + 1; K = 2; } else { K = K + 1; } done = 1; output (i);

– © Yohai Devir 2007 Technion - IIT

– © Yohai Devir 2007 Technion - IIT