Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
ポーリングと割り込み
Search
Satoru Takeuchi
PRO
July 16, 2025
Technology
200
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
ポーリングと割り込み
以下動画のテキストです
https://youtu.be/QY1O_XzKN64
Satoru Takeuchi
PRO
July 16, 2025
More Decks by Satoru Takeuchi
See All by Satoru Takeuchi
119-多機能ファイルシステムBtrfs_のコピー.pdf
sat
PRO
1
82
Linuxカーネルの インタフェースは変わりうる?
sat
PRO
1
110
あなたの知らないバージョン命名規則
sat
PRO
3
930
Rook: Intro and Deep Dive with Ceph
sat
PRO
1
82
Machine Check Exception
sat
PRO
2
73
バイナリダンプの模様を読む
sat
PRO
0
120
cpコマンドはディスク上でデータを コピーしないことがある
sat
PRO
3
120
114-ファイルのshallow_copy.pdf
sat
PRO
2
70
113-Btrfsのスナップショット.pdf
sat
PRO
0
50
Other Decks in Technology
See All in Technology
OneLakeをデータソースにした AI Search(Foundry IQ)の ライフサイクル管理
ryuseiiida
0
230
2拠点SRE活動始めてみた | sogaoh's LT @ ホンマでっかSRE勉強会 #3
sogaoh
PRO
0
240
業務でAWSをあまり使っていない私が、AWSへのモチベを保つ方法
smt7174
0
150
IoTとは〜? 数字で見るSORACOM UG【SORACOM UG Explorer 2026】
soracom
PRO
0
190
DBTS2026 盛り上がってますか!?Databricksが実現するAI時代のデータ基盤
akuwano
1
170
「いつか使う」の「いつか」は来ない 〜AI駆動開発における「作らない」判断について〜
ikki0006
0
120
AX時代の自治体支援リソース再配分と役割分担の再構成:戦略とロードマップ(概要)
sishi2026
0
200
公共分野での生成AI活用
toru_kubota
1
220
GCASアップデート(202607-202610)
techniczna
1
180
サボる子はいねぇがー!AgentCoreハーネスの脆弱性に学ぶ、エージェントの入力バリデーション
iwamot
PRO
4
270
Flutter Widget Previewerで始めるUIプレビューとVRTの自動化
sakusaku3939
0
210
E2Eってつらくないですか?E2Eの管理コストを下げる手段とその実践
akaboshinit
6
3k
Featured
See All Featured
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
2
670
First, design no harm
axbom
PRO
2
1.4k
How to Talk to Developers About Accessibility
jct
2
610
Chasing Engaging Ingredients in Design
codingconduct
0
390
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
460
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
3.1k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
560
Fashionably flexible responsive web design (full day workshop)
malarkey
409
67k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
6
1.3k
Site-Speed That Sticks
csswizardry
13
1.6k
BBQ
matthewcrist
90
10k
Transcript
ポーリングと割り込み Jul. 16th, 2025 Satoru Takeuchi X: satoru_takeuchi 1
おさらい • おさらい: デバイスへのアクセスの流れ 1. CPU: デバイスのレジスタを介してデバイスに処理を依頼 2. デバイス: なんらかの処理をする
3. デバイス: 処理が完了する 4. デバイス: 処理の完了をCPUが認識できるようにする 5. CPUが完了を認識して、結果に応じた処理をする • 本動画のトピック: step4をどのように実現するか 1. ポーリング ▪ 📝 「その 100 デバイスドライバ」の方法 ▪ デバイスがレジスタの値を更新して、 CPUがその値を読む 2. 割り込み ▪ デバイスからCPUに処理の完了を通知する 2
ポーリング: シンプルなもの 3 p0 p1 p 0 デバイスドライバ p 0
時間 p1 p0 … CPU デバイス 依頼された処理を実行中 デバイスドライバに処 理を依頼 デバイスに処理を依頼 処理完了を示す値を レジスタに書き込む レジスタをひたすら読む 処理完了を検出 何もしていない 何もしていない
ポーリング: 他のことをしながら定期的に実行 4 p0 p1 p 0 p 0 時間
p1 CPU デバイス 依頼された処理を実行中 デバイスドライバに処 理を依頼 デバイスに処理を依頼 処理完了を示す値を レジスタに書き込む 所定間隔でレジスタ読み出し 処理完了を検出 デバイスドライバ p1 p1 p1 p1 p1 何もしていない
割り込み 5 p1 p0 p1 p 0 p 0 時
間 p1 p0 … CPU デバイス 依頼された処理を実行中 デバイスドライバに 処理を依頼 デバイスに処理を依頼 処理完了を検出 デバイスドライバ デバイスドライバ 処理完了を通知 デバイスの処理完了まで 他の処理を動かせる 何もしていない 何もしていない
どっちが使われている? • ほとんどの場合は割り込みを使う • 稀にポーリングを使うこともある ◦ 割り込みをサポートしていない ◦ 極めて低いレイテンシを求められる ▪
e.g. NICのパケット処理に専用コアを割り当てる DPDK • 1つのドライバ内で両者を使い分けることもある ◦ 負荷が低いときは割り込み、高いときはポーリング 6
まとめ • デバイスの処理完了を待つしくみ ◦ ポーリング: CPUがデバイスのレジスタを定期的に読み出す ◦ 割り込み: デバイスがCPUに処理の完了を通知する •
主に割り込みを使うが、ポーリングを使う場合もある 7