Network Hub

AddressNameBufferCommandDestination
0hubwait
1node 1hello worldsend2
2node 2listen0
3node 3Do you recognize me?send1
4node 4CQ CQsend3
5node 5Loop backsend5

クロストークのデッドロック対策

ハブもノードもアドレスの奇数と偶数で送信専用・受信専用に分けて、2アドレスずつ占有する。それでも、クロストークのデッドロックは回避できそうで回避できない。なぜなら、ハブで送信と受信のバッファをスワップする必要があるのだが、そのタイミングがシビアでハブ自身にはわからないから。初めから全てのパケットの順序が完璧にわかっていれば、完璧なタイミングで問題なく送受信できるだろう。ノンブロッキングのハブなんて夢のまた夢だ。

data flow between hub and nodes
Blocking Hub
 
data flow between nodes(non-blocking); the bundle is hub function
Non-Blocking Hub (arrows from odd numbers to even numbers are the bundle which is functioning in the hub)