HiRA: A Methodology for Deadlock Free Routing in Hierarchical Networks on Chip Rickard Holsmark 1, Maurizio Palesi 2, Shashi Kumar 1 and Andres Mejia 3 1 Jönköping University, Sweden 2 University of Catania, Italy 3 Technical University of Valencia, Spain NoC Symposium San Diego, May 10 13, 2009
Contents Introduction Hierarchical networks Deadlock free hierarchical routing Hierarchical deadlock free routing methodology Basic idea and theoretical framework Design methodology Evaluation Simulation results Conclusions 2
The Road to Network on Chip and Beyond Transistor Integrated Circuits Microprocessor 1960 1970 1980 System on Chip 1990 Networks on Chip (NoC) Networks of NoCs Evolution of building blocks in electronic system design 2000 2010 3
Hierarchical Networks Hierarchical networks in system design Reuse of networks as subnets Partitioning large networks Examples of hierarchical NoCs Hybrid ring/mesh Optimization global/local traffic (Bourduas and Zilic, 2007) HiNoC, mesh/fat-tree Efficient GALS, asynchronous mesh/synchronous tree (Hollstein et al., 2006) Our approach to hierarchical networks Heterogeneous interconnect Subnets and subnet interconnect Routing Use optimal routing algorithm for each subnet 4
Issues when Combining Networks Different structures Switching Store and forward wormhole Routing control Source distributed Deadlock strategy Avoidance recovery Physical implementation Given identical structures Different routing algorithms -> deadlock problems 5
Deadlock Free Routing when Combining Networks Each subnet deadlock free Deadlock free? -Whole network must be considered Routing Alg. S1 Routing Alg. S2 Shared Mem Routing Alg. N Shared Mem Network Routing Alg. S3 Routing Alg. S4 6
Hierarchical Deadlock Free Routing Each subnet deadlock free Deadlock free? Deadlock free subnets + rules + external routing algorithm Routing Alg. S1 Routing Alg. S2 Routing Alg. H Shared Mem Routing Alg. S1 Routing Alg. S2 Shared Mem Network Routing Alg. E Routing Alg. S3 Routing Alg. S4 Routing Alg. S3 Routing Alg. S4 7
Revising Packet Deadlocks Deadlock Packets involved in a circular wait Risk increased by using wormhole switching Avoid/recover/drop Avoidance techniques Analysis: Channel dependency graphs (CDG), Turn-model, Channel wait for graphs (CWG) Implementation: Restrict packet routes Examples of algorithms Odd-even, X-Y, Negative-first, Up/Down 8
Deadlock Example Four packets: P1,..,P4 Require turns:,.., -Based on previous decisions (turns) Packet Deadlock No Packet Deadlock P1 Restrict turn 1 2 1 2 P2 P2 P1 P4 P4 3 4 3 4 P3 P3 9
Deadlock Freedom and CDG Topology 1 2 Channel dependency graph (CDG) l 21 3 4 l 13 l 31 l 12 l 43 l 24 l 42 Cycles in CDG = not deadlock free l 34 Cut all cycles Implement routing restrictions l 21 l 12 1 2 l 13 l 31 l 24 l 42 = deadlock free l 43 3 4 l 34 10
Deadlocks when Interconnecting Networks Two deadlock free networks interconnected Subnet A Subnet B Possibility of cycle in CDG May not be deadlock free and connected Analyze CDG Bi-directional routing restriction Cycle 11
Deadlock Free Interconnection of Networks The two networks again No CDG cycle formed Deadlock free and connected Safe interconnection nodes Subnet A Subnet B Analyze CDG Moved routing restrictions No cycle 12
Deadlock Free Hierarchical Routing Method for interconnecting deadlock free (sub-) networks Resulting network is deadlock free and connected Internal subnet routing algorithms un-changed Hierarchical network structure Subnets Networks with independent (deadlock free) routing algorithms Boundary nodes Subset of nodes in a subnet that connects to other subnets External links Links between subnets (are not in any subnet) 13
Hierarchical Network Structure Subnet S 1 S 3 Internal nodes/links S 2 External link S 4 S 6 Boundary node S 5 14
Hierarchical Routing Algorithm Building blocks Subnet routing algorithms Given, routes inside subnets (internal subnet links) External routing algorithm Routes between subnets (external and internal links) Safe boundary nodes (interconnections nodes) Prohibits un resolvable CDG cycles Defined in each subnet Complete hierarchical routing algorithm Combination of subnet internal and external algorithms Usage of safe boundary nodes enable deadlock freedom 15
Hierarchical Route Example Routing a packet from subnet S i to subnet S j o Source node n s, destination node n d 1. Node n s : R G (n d )=R i (b s ) (internal route) 2. Node b s : R G (n d )=R G (b d ) (external route) b s Internal routing Subnet Salgorithm R i i Internal routing restricitons n s Internal routing algorithm R i 3. Node b d : R G (n d )=R j (n d ) (internal route) b d n d External routing algorithm R G External routing restriciton Subnet S j 16
Safe Boundary Nodes Example of safe boundary nodes in a subnet Routing algorithm in subnet S 6 : Negative first Subnet S 6 CDG Negative-first routing restrictions Safe if no CDG path All safe Boundary nodes (4 of 6) 17
Theoretical Foundation Theorem: A hierarchical routing algorithm is deadlock free and connected if all subnet routing algorithms are deadlock free, the external routing algorithm is deadlock free and subnets are interconnected by safe boundary nodes Proof logic Subnet CDGs and external CDG acyclic External CDG: Restrictions on safe boundary nodes Combined dependencies Safe boundary nodes: Only from one boundary node to another boundary node Acyclic CDG for combined (hierarchical) algorithm: Deadlock free All restricted external routes included in analysis: Connected 18
Identification of Safe Boundary Nodes Termination Not succesful termination Succesful termination Unsafe Cycle enabled Safe Cycle disabled l 13 l 21 l 12 l 31 l 43 l 24 l 42 l 13 l 21 l 12 l 31 l 43 l 24 l 42 l 34 l34 19
Finding Safe Nodes Possible Safe nodes? Depends on routing algorithm Two main types (Algorithms with Deadlock freedom based on acyclic CDG) Deterministic routing All network nodes are safe nodes (assuming bi-directional links) Adaptive routing Not all nodes are safe nodes Number of and positions of safe nodes vary 20
Designing External Routing Algorithm Deadlock free external routing algorithm Un-changed internal algorithms Internal paths between safe boundary nodes given If cycles in external CDG: Restrictions on boundary node links (external internal, external external) Affects only external traffic External routing algorithm = normal routing algorithm Links: External links and internal paths between boundary nodes Nodes: Boundary nodes and internal nodes on internal boundary node paths 21
Example: External Algorithm External routing restrictions Cycle free external CDG (effectíve dependencies, safe nodes) S 1 S 3 S 4 S 2 X-Y S 6 S 5 External restrictions 22
Interconnection of Y X and X Y Networks Y-X X-Y Y-X Y-X X-Y Y-X Simply connect: -Cycle, not deadlock free Y-X External routing X-Y X-Y Y-X Hierarchical: -No cycles, deadlock free No path Not allowed (X-Y) 23
Evaluation Set Up Noxim network simulator Wormhole switching Packet size randomly between 2 and 8 flits Traffic types Synthetic: Standard types (random, transpose, ) Application: Communication graphs from research papers (Hu and Marculescu, 2005), (Yoon, Lee and Park, 2006), (Jaspers and de With, 1999), (van der Tol and Jaspers, 2001) Destinations Local traffic: Communication within subnets Global traffic: Communication between subnets 24
Average Delay Synthetic Traffic Average delay for each routing algorithm under varying global /local ratio 100 90 80 70 Four subnets with different traffic types Average delay (cycles) 60 50 40 30 XY Odd-Even West-First Hierarchical 20 10 0 0% 2% 4% 9% 13% 17% 22% Global to Local ratio 25
Throughput Jitter Application Traffic Normalized throughput jitter for each algorithm and application Five core subnets + one memory subnet Normalized Throughput Jitter 1.80 1.60 1.40 1.20 1.00 0.80 0.60 0.40 0.20 0.00 NegativeFirst WestFirst APSRA XY NorthLast OddEven Hierarchical MMS-Enc MMS-Dec PIP MWD MIMO-OFDM 26
Conclusions Concept of hierarchy is useful for designing large NoCs Helps to raise the level of reuse from components to subnets Building networks with heterogeneous topology, heterogeneous routing,... Partition a large network for mapping applications, testing, fault tolerance,... New Issues and concepts Deadlock free routing and connectivity Safe boundary nodes Challenges and future work Pessimistic assumption of interconnecting subnets using only safe boundary nodes Unsafe nodes can be used in certain cases Node addressing and router design Traffic management and congestion control in hierarchical networks 27
Awake? Thank you for Listening! Questions? 28