[理工] 計算機組織與結構-拜託各位

看板Grad-ProbAsk作者 (沒事少說話)時間17年前 (2009/04/17 12:28), 編輯推噓1(103)
留言4則, 1人參與, 最新討論串1/1
For the pipeline in computer arithmetic, consider the following snippet of code: For I = 1 TO 100 DO {A[i] = (B[i]*C[i]) + D[i]} Assume that each operation, multiplication and addition, requires 10 ns to complete.A non-pipelined uniprocessor takes 20 ns to calculate A[i], and 2000 ns to execute the code. A pipelined unit could break this computation into two stages in which the first stage performs the multiplication and the second stage performs the addition,where the latches store the output of each stage in the pipeline and each latch needs 2ns to load data. (1) Draw the above two-stage pipeline scheme (including the latches). (2) Calculate the time required to execute the above code (including the latching time). 想請問題高應大電子系的考題,我真的看不太懂,板上的各位可以指點我一下嗎? 前面幾間放榜完,才發現,機會有點渺茫,這是我最後一間了,拜託各位了!! -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 163.23.5.176

04/17 17:32, , 1F
[2] 第一管執行乘法花費10ns、第二管執行加法花費10ns
04/17 17:32, 1F

04/17 17:33, , 2F
管線的時脈為max{10ns,10ns}+2ns =12ns
04/17 17:33, 2F

04/17 17:33, , 3F
總共花費時間為{100+2-1}*12ns = 1212ns
04/17 17:33, 3F

04/17 17:35, , 4F
[1]畫圖的話能請你翻課本嗎? XD..
04/17 17:35, 4F
文章代碼(AID): #19w0LHdQ (Grad-ProbAsk)