[理工] [計組] polling, DMA, interrupt

看板Grad-ProbAsk作者 (icehead)時間11年前 (2013/01/04 11:36), 編輯推噓2(2010)
留言12則, 5人參與, 最新討論串1/1
If we want the lowest latency for an I/O operation to a single I/O device, the order is polling, DMA and interrupt driven. Ans: True 想請問的是為什麼一次DMA的一次IO的latency會比interrupt來的短 ? 麻煩版上大大幫解惑 thanks. -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 119.14.77.145

01/04 14:17, , 1F
想想那個流程 在DMA一次處理IO的過程中 並非全程需求CPU
01/04 14:17, 1F

01/04 14:17, , 2F
但interrupt呢? 卻要跑IHR 甚至在那之前os還得驗證
01/04 14:17, 2F

01/04 14:18, , 3F
所謂的latency是針對cpu來討論
01/04 14:18, 3F

01/04 17:29, , 4F
簡單講法,interrupt 是泡咖啡機,interrupt 是瑪麗亞
01/04 17:29, 4F

01/04 17:30, , 5F
瑪莉亞泡好咖啡送到你前面,咖啡機你還要走去拿咖啡
01/04 17:30, 5F

01/04 17:31, , 6F
你就是 cpu...你想哪個對你來說花比較少時間
01/04 17:31, 6F

01/04 17:31, , 7F
洪逸上課講的...XD..很好記
01/04 17:31, 7F

01/05 06:23, , 8F
interrupt是咖啡機也是瑪麗亞?
01/05 06:23, 8F

01/05 06:25, , 9F
不太懂比喻
01/05 06:25, 9F

01/05 13:07, , 10F
DMA是馬麗亞才對
01/05 13:07, 10F

01/05 16:29, , 11F
#1GjZZALx 這篇的推文也有三個方法的例子
01/05 16:29, 11F

01/05 16:29, , 12F
感謝以上大大幫忙 :)
01/05 16:29, 12F
文章代碼(AID): #1GvavHx_ (Grad-ProbAsk)