Worked examples — Infinity Fabric - mesh interconnects
6.3.11 · D3· Hardware › Interconnects, Buses & SoC › Infinity Fabric - mesh interconnects
Yeh parent topic on Infinity Fabric & mesh interconnects ka "worked examples" deep-dive hai. Parent note ne tumhe kya hai fabric yeh bataya aur do starter examples diye. Yahan hum har case class dhundte hain — har woh shape ka question jo exam ya real design review phenk sakta hai — aur har ek ko zero se solve karte hain.
Koi bhi number aane se pehle, teen quantities yaad rakho jo hum baar baar use karte hain, plain words mein:
Do clock names baar baar neeche aate hain; inhe abhi hi jaano taaki koi bhi symbol kabhi surprise na ho:
Bandwidth examples mein baar baar use hone wala ek aur term:
The scenario matrix
Is topic ke baare mein har question in cells mein se kisi ek mein aata hai. Hamara kaam hai ki koi bhi cell chhutti na rahe.
| Cell | Kya cheez ise alag banati hai | Covered by |
|---|---|---|
| A. Bandwidth — one direction | frequency × width, single lane | Ex 1 |
| B. Bandwidth — bidirectional / ratio | double karo, phir FCLK:MCLK ratio check karo | Ex 2 |
| C. Routing — generic hop count | Manhattan distance on a mesh | Ex 3 |
| D. Routing — degenerate (same row / same node) | ek axis mein zero, ya zero total | Ex 4 |
| E. Ring vs mesh — the crossover | mesh actually kab jeet ta hai? difference ka sign | Ex 5 |
| F. Bisection bandwidth — the "cut" | ek slice cross karne wale links gino | Ex 6 |
| G. Chiplet latency — the multi-hop word problem | ns aur cycles ko clock domains ke paar mix karo | Ex 7 |
| H. Coherency traffic — O(N) vs O(k) | probes ka limiting/scaling behaviour | Ex 8 |
| I. Exam twist — mismatched ratio bottleneck | fabric memory se slower: kaun jeet ta hai? | Ex 9 |
Hum A→I order mein chalenge.
Cell A — Bandwidth, one direction
Forecast: pehle order of magnitude guess karo — tens of GB/s? Hundreds? Apna guess likh lo.
- Frequency ko ticks per second mein convert karo. cycles/s. Yeh step kyun? Bandwidth bytes per second hai, isliye denominator mein seconds chahiye. GHz already "per second" deta hai.
- Width ko ticks se multiply karo. Har tick bytes move karta hai, isliye Yeh step kyun? Units cancel ho jaate hain: cycle over cycle disappear ho jaata hai, bytes/second bachta hai — exactly yahi "bandwidth" ka matlab hai.
- Naam do. . Yeh step kyun? by definition ek gigabyte per second (GB/s) hai, isliye number ko us unit mein likhte hain jo har jagah datasheets mein quote hoti hai — same value, human-readable naam.
Verify: Units: ✓. Sanity: 32 bytes ek 64-byte cache line ka aadha hai, isliye almost 2 billion half-lines per second move ho rahi hain — comfortably "tens of GB/s" range mein.
Cell B — Bidirectional & the clock ratio
Forecast: kya bidirectional simply double ho jaata hai? Aur kya fabric is memory ke against ya geared hai?
- Double karo. Ek link ke har direction ke liye alag wire hoti hai, isliye Yeh step kyun? Send aur receive ek saath independent lanes par chalte hain — share nahi karte, isliye hum unhe add karte hain.
- DDR label se MCLK nikalo. "DDR4-3600" matlab (mega-transfers/s). DDR double data rate hai — har clock mein do transfers — isliye memory clock hai . Yeh step kyun? Ratio clock se clock compare karta hai, isliye actual MCLK recover karne ke liye transfer rate se "double" nikaalna padta hai.
- True ratio batao. aur , isliye gearing hai — nahi. Dono lockstep mein tick karte hain. Yeh step kyun? Ratio ko correctly naam dena Cell B ka poora point hai; ek fabric har memory tick mein ek packet move karta hai, jo AMD ka ideal tuning target hai.
- Memory bandwidth compute karo (ek direction). Is platform mein do channels hain (dual-channel — upar Memory channel definition dekho), har ek wide, transfers/s par: Yeh step kyun? Fabric ko memory se same direction mein compare karna zaroori hai taaki dekh sakein ki fabric ek read stream ke saath chal sakta hai ya nahi — aur channel count platform se padha jaata hai, assume nahi kiya jaata.
Verify: ✓; isliye ratio ✓. Fabric-per-direction () memory-per-direction (), isliye ek read burst fabric mein bina pile up kiye drain ho jaata hai. Cell I neeche dikhata hai kya hota hai jab yeh ratio toot ta hai.
Cell C — Generic routing hop count
Forecast: kya yeh straight-line distance hai, ya grid-walk distance?
Figure 1 — XY routing on a 4×4 mesh. Alt: 16 dots ki ek grid; ek teal source dot (1,0) par aur ek plum destination (3,3) par, ek orange arrowed path se jude hue jo pehle 2 steps east phir 3 steps north jaata hai, exactly ek baar turn karta hai. Yeh picture yeh point clear karta hai ki packet grid par chalta hai, kabhi diagonally nahi.

- Woh distance define karo jo chahiye. Grid par tum diagonally nahi ud sakte; links ke along chalna padta hai. Sahi measure hai Manhattan distance:
- Pehle X ("XY routing" ka "X"). se tak: hops east. X pehle kyun? Dimension-ordered routing ek order fix karta hai (pehle X, phir Y) taaki packets ek doosre ko loop mein na chase karein — yeh deadlock prevent karta hai (parent note, virtual channels).
- Phir Y. se tak: hops north.
- Add karo. Total hops. Path: — Figure 1 mein orange path dekho: yeh exactly ek baar turn karta hai.
Verify: Manhattan ✓. Ek single turn XY routing confirm karta hai (X leg, phir Y leg).
Cell D — Degenerate routing (zeros)
Degenerate cases se pehle, average-hop formula ko scratch se banate hain taaki yeh page apne aap par khada ho sake.
Socho ki tum dots lambi ek line ke ek axis par randomly do nodes pick kar rahe ho. Average par dono picks lagbhag ek tehayi dur land karti hain — expected gap hai. (Intuition: agar tum length ki ek stick par do points uniformly drop karo, unke beech average distance hai — points zyada baar opposite ends ki bajaye ek doosre ke paas hote hain.) Ek mesh mein ek X axis aur ek Y axis hai, aur do gaps simply add ho jaate hain:
Yaad rakho: yeh sabhi pairs par average hai, kisi ek specific route ki distance nahi. Yahi distinction exactly woh hai jo neeche degenerate cases expose karte hain.
Forecast: "average hops " yahan kya deta hai, aur kya yeh galat hai?
- Case (a): same X column. hops (purely Y). Ise kyun point out karte hain? Averaged formula predict karega — lekin yeh sabhi pairs ka average hai, is specific pair ka nahi. Ek aligned pair ke liye X term exactly zero hai. Average ko kabhi ek single deterministic route par apply mat karo.
- Case (b): source = destination. hops. Message kabhi local port nahi chhodta. Yeh kyun matter karta hai: zero hops matlab zero router-to-router latency; sirf local agent handoff ka cost hai. Degenerate lekin real (ek core apna L2 slice hit kar raha hai).
Verify: (a) ✓; (b) ✓. Dono maximum possible hop count se hain, aur — valid bounds ke andar.
Cell E — Ring vs mesh crossover (win ka sign)
Pehle, do symbols jinpar yeh example jeeta hai — inhe clearly samjhe bina aage mat padho:
Forecast: tiny (maan lo 4 cores) par kaun lower hai? Solve karne se pehle guess karo.
Figure 2 — hop-count crossover. Alt: warm-paper plot par do curves; ek teal straight line N/4 (ring) aur ek orange curve 2·sqrt(N)/3 (mesh) jo N=7.1 ke paas cross karti hain, plum dashed line se mark ki gayi; crossing ke left mein ring lower hai, right mein mesh lower hai. Yeh picture exactly woh core count dikhata hai jahan mesh jeetna shuru karta hai.

- Inequality set up karo. Mesh jeet ta hai jab uska hop count chhota ho: Yeh step kyun? dono ke liye same hai, isliye cancel ho jaata hai — winner purely hop count par depend karta hai.
- ke liye solve karo. Dono sides ko 12 se multiply karo: , yani , isliye , deta hai . Numbers plug in kyun nahi karte? Hum crossover chahte hain, ek data point nahi — inequality solve karne se boundary directly milti hai.
- Real mesh tak round karo. Sabse chhota perfect square jahan hai woh () hai.
- Boundary par sign check karo. par: ring , mesh hops → ring jeet ta hai (mesh tiny core counts par haarta hai!). par: ring , mesh → mesh jeet ta hai. ka sign unke beech flip karta hai.
Verify: : mesh , ring → mesh smaller ✓. : mesh ring ✓ (ring jeet ta hai, parent ke "~10–12 core" real-world crossover se match karta hai jab router overhead add kiya jaaye). General topology trade-off ke liye 7.2.4-Network-Topologies bhi dekho.
Cell F — Bisection bandwidth (the cut)
Forecast: kaun si topology ke paas beech span karne wale zyada wires hain?
Figure 3 — the bisecting cut. Alt: do side-by-side diagrams; left mein, ek 16-node ring jisme ek teal dashed horizontal cut exactly 2 links kaat ti hai; right mein, ek 4×4 mesh jisme ek teal dashed vertical cut 4 links kaat ta hai (ek column). Mesh ke paas clearly do gune zyada links crossing hain. Isliye mesh bisection bandwidth ke saath scale karta hai.

- Bisection bandwidth define karo. Network ko do equal halves mein kaato; bisection bandwidth us cut dwara severed har link ki total bandwidth hai. Yeh metric kyun? Agar dono halves poori takat se ek doosre se baat karein, toh yeh unke beech traffic ki ceiling hai — real "kitna flow ho sakta hai" number.
- Ring cut. Ring ek single loop hai; use aadha karne se exactly 2 links cut hote hain (do arcs). Figure 3 mein teal dashed cut dekho.
- Mesh cut. Ek mesh ko beech mein cut karne se ek column of vertical links cut hote hain: 4 links (). kyun? Cut grid ki ek puri row/column ke across chalta hai, aur ek grid mein links hain jo ise span karte hain.
- Bandwidth tak. Ring ; mesh → mesh ke paas bisection bandwidth hai.
Verify: ratio ✓; ✓; ✓. Isliye mesh bandwidth ko ke saath scale karta hai jabki ring flat rehta hai.
Cell G — Chiplet latency word problem (mixed units)
Forecast: kaun sa leg dominate karta hai — on-chip cycles ya die-crossing ns?
- Cycles ko ns mein convert karo. par ek cycle lasti hai. Isliye cycles . Pehle convert kyun? Tum cycles aur nanoseconds directly add nahi kar sakte — woh alag clock domains mein rehte hain. Sabko ek unit (ns) mein lao.
- Die crossings add karo. do fabric hops ke liye. Sirf add kyun karte hain? Ek single serial path ke along latencies accumulate hoti hain — packet ek leg karta hai, phir doosra, isliye total time sum hai.
- Total. . Yeh answer kyun hai? Ab sab kuch nanoseconds mein hai, isliye teen serial legs end-to-end latency tak add ho jaate hain: .
Verify: ✓; total ✓. Die-crossing ke on-chip ke ko dwarf karte hain — yahi "chiplet penalty" hai jo parent mention karta hai, aur isliye 6.2.8-NUMA-Architecture matter karta hai: distant memory zyada door feel karta hai.
Cell H — Coherency traffic scaling (limiting behaviour)
Forecast: kya directory traffic total cores ke saath badhta hai ya sirf sharers ke saath?
- Broadcast: sab ko probe karo. Har write sabhi doosre cores ko probe bhejta hai: messages. par: ; par: . kyun? Broadcast ko nahi pata kisne line rakhi hai, isliye writer ke alawa sab cores se poochna padta hai — yahi scaling hai jiske baare mein parent warn karta hai.
- Directory: sirf sharers ko probe karo. Home L3 slice ko sharer list pata hai, isliye yeh probes bhejta hai se independent. par: ; par: . Constant kyun? Directory sharers ko explicitly track karta hai, isliye traffic hai — chip ke badhne par flat. Isliye mesh CPUs directories use karte hain (dekho 6.3.5-Cache-Coherency-Protocols).
- par ratio. Broadcast/directory — directory ke saath gune kam messages. Ratio kyun lete hain? Yeh saving ko size-free way mein express karta hai — "21 times less traffic" woh headline hai jo ek designer care karta hai, units se independent.
Verify: : aur ✓; directory: aur ✓; ratio ✓. Broadcast linearly blow up karta hai; directory flat rehta hai — woh limiting behaviour jo 64-core fabrics ko feasible banata hai.
Cell I — Exam twist: broken ratio bottleneck
Forecast: faster memory ke saath, kya tumhe faster real bandwidth milti hai — ya koi cheez upstream cap karti hai?
- Fabric one-direction bandwidth. . Ek direction kyun? Read stream memory→core ek single direction mein flow karta hai; like se like compare karo.
- Memory one-direction bandwidth. Given hai (do channels, har ek, ).
- Bottleneck minimum hai. Data dono se guzarna chahiye; slower stage throughput cap karta hai: Min kyun, average kyun nahi? Ek pipeline apni slowest stage ki speed par chalta hai — fabric ek hard wall hai jisse memory bytes squeeze hokar guzarni padti hain.
- Lesson. Lagging FCLK ke saath faster RAM memory bandwidth waste karta hai. Fix: FCLK badhao (ya penalty accept karo). 6.4.3-PCIe-Topology se compare karo jahan ek slow root link similarly device throughput cap karta hai.
Verify: fabric ✓; ✓; wasted ✓. Exam trap: bada memory number matlab nahi bada real bandwidth.
Recall Quick self-test
Ek mesh, , XY routing — kitne hops? ::: hops (Cell D, X-only) Fabric at , bidirectional? ::: (Cell B) 64-core chip par sharers ke liye directory probes? ::: , N se independent (Cell H) Ring vs mesh at — hops par kaun jeet ta hai? ::: Ring () — mesh tiny N par haarta hai (Cell E) Fabric , memory — effective? ::: (Cell I)