Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series...

24
Atlantis Ambient and Pervasive Intelligence Volume 7 Series Editor Ismail Khalil, Johannes Kepler University, Linz, Austria For further volumes: www.atlantis-press.com

Transcript of Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series...

Page 1: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Atlantis Ambient and Pervasive Intelligence

Volume 7

Series Editor

Ismail Khalil, Johannes Kepler University, Linz, Austria

For further volumes:www.atlantis-press.com

Page 2: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Aims and Scope of the Series

The book series ‘Atlantis Ambient and Pervasive Intelligence’ publishes highquality titles in the fields of Pervasive Computing, Mixed Reality, WearableComputing, Location-Aware Computing, Ambient Interfaces, Tangible Interfaces,Smart Environments, Intelligent Interfaces, Software Agents and other relatedfields. We welcome submission of book proposals from researchers worldwidewho aim at sharing their results in this important research area.

For more information on this series and our other book series, please visit ourwebsite at:

www.atlantis-press.com/publications/booksAtlantis Press29, avenue Laumière75019 Paris, France

Page 3: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Abderazek Ben Abdallah

Multicore Systems On-Chip:Practical Software/HardwareDesign

Second Edition

Page 4: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Abderazek Ben AbdallahAdaptive Systems LaboratoryUniversity of AizuAizuwakamatsuJapan

ISSN 1875-7669ISBN 978-94-91216-91-6 ISBN 978-94-91216-92-3 (eBook)DOI 10.2991/978-94-91216-92-3

Library of Congress Control Number: 2013937097

� Atlantis Press and the author 2013This book, or any parts thereof, may not be reproduced for commercial purposes in any form or by anymeans, electronic or mechanical, including photocopying, recording or any information storage andretrieval system known or to be invented, without prior permission from the Publisher.

Printed on acid-free paper

Page 5: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

To The University of Aizu incommemoration of its 20th anniversary

Page 6: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Preface

Systems On-Chip designs have evolved over time from fairly simple unicoresingle memory designs to complex homogeneous/heterogeneous multicore SoCarchitectures consisting of a large number of IP (Intellectual Property) blocks onthe same silicon. To meet the challenges arising from high computational demandsposed by latest consumer electronic devices, most current systems are based onsuch paradigm, which represents a real revolution in many aspects of computing.

The attraction of multicore processing for power reduction is compelling. Bysplitting a set of tasks among multiple processor cores, the operating frequencynecessary for each core can be reduced, thereby facilitating a reduction in thevoltage on each core. Because dynamic power is proportional to the frequency andto the square of the voltage, we are able to obtain a sizable gain, even though wemay have more (multiple?) cores running.

As more and more cores are integrated into these designs to share the everincreasing processing load, the primary challenges are geared toward efficientmemory hierarchy, scalable system interconnect, new programming models, andefficient integration methodology for connecting such heterogeneous cores into asingle system capable of leveraging their individual flexibility.

Current design methods are inclined toward mixed hardware/software (SW/HW)codesigns, targeting multicore SoCs for application specific domains. To decide onthe lowest cost mix of cores, designers must iteratively map the devices func-tionality to a particular HW/SW partition and target architectures. In addition, toconnect the heterogeneous cores, the architecture requires high performance-basedcomplex communication architectures and efficient communication protocols, suchas hierarchical bus, point-to-point connection, or the recent new interconnectionparadigm—Network-on-Chip. Software development also becomes far morecomplex due to the difficulties in breaking a single processing task into multipleparts that could be processed separately and then reassembled later. This reflectsthe fact that certain processor jobs could not possibly be easily parallelized to runconcurrently on multiple processing cores and that load balancing betweenprocessing cores especially heterogeneous cores is extremely difficult.

This second edition of this book stands independent and we have made everyattempt to make each chapter self-contained as well. It is organized in 11 chapters.The first chapter introduces Multicore Systems On-Chip (MCSoCs) architectures

vii

Page 7: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

and explores SoCs technology and the challenges it presents to organizations anddevelopers building next generation multicore SoCs based systems.

Understanding the technological landscape and design methods in some level ofdetails is very important. This is because so many design decisions in multicorearchitecture today are guided by the impact of the technology. Chapter 2 presentsdesign challenges and conventional design methods of MCSoCs. It also describes aso called scalable core-based method for systematic design environment ofapplication specific heterogeneous multicore SoC architectures. The architecturedesign used in conventional methods of multicore SoCs and custom multipro-cessor architectures are not flexible enough to meet the requirements of differentapplication domains and not scalable enough to meet different computation needsand different complexities of various applications. Therefore, designers should beaware of existing design methods and also be ready to innovate or adapt appro-priate design methods for individual target platform.

Understanding the software and hardware building blocks and the computationpower of individual components in these complex MCSoCs is necessary fordesigning power, performance, and cost-efficient systems. Chapter 3 describes indetails the architectures and functions of the main building blocks that are used tobuild such complex multicore SoCs. Students with relevant background in mul-ticore SoC building blocks could effectively skip some of the materials mentionedin this chapter. The knowledge of these aspects is not an absolute requirement forunderstanding the rest of the book, but it does help novice students or beginners toget a glimpse of the big picture of a heterogeneous or homogeneous MCSoCorganization.

Whether homogeneous, heterogeneous, or hybrid multicore SoCs, IP cores mustbe connected in a high-performance, scalable, and flexible manner. The emergingtechnology that targets such connections is called an on-chip interconnectionnetwork, also known as a network on chip (NoC), and the philosophy behind theemergence of such innovation has been summarized by William Dally at StanfordUniversity as route packets, not wires. Chapters 4–6 investigate 2D-NoC, 3D-NoC, and 2D/3D NoC Network Interface (NI) designs. These chapters focus on thearchitecture and design of Network-on-Chip (NoC) and the NI. Efficient, light-weight NI interfaces are critical for overall latency reduction. For an effectiveconcurrent multicore SoCs, a programmer needs a fast on-chip network transport,fast and easy-to-use network interfaces, and predictable network performance.These three chapters are all very important part of the book since they allow thereader to understand what needed microarchitecture for on-chip routers and net-work interfaces are essential toward meeting latency, area, and power constraints.Reader will also understand practical issues about what system architecture(topology, routing, flow control, NI) is most suited for these on-chip networks.

With the rise of multicore and many-core systems, concurrency becomes amajor issue in the daily life of a programmer. Thus, compiler and softwaredevelopment tools will be critical toward helping programmers create high per-formance software. Programmers should make sure that their parallelized programcodes would not cause race condition, memory access deadlocks, or other faults

viii Preface

Page 8: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

that may crash their entire systems. Chapter 7 describes a novel parallelizingcompiler design for high performance computing.

Power dissipation continues to be a primary design constraint and concern insingle and multicore systems. Increasing power consumption not only results inincreasing energy costs, but also results in high die temperatures that affect chipreliability, performance, and packaging cost. Chapter 8 provides a detailedinvestigation of power reduction techniques for multicore SoC at components andnetwork levels. Energy conservation has been largely considered in the hardwaredesign, in general and also in embedded multicore system components, such asCPUs, disks, displays, memories, and so on. Significant additional power savingscould be also achieved by incorporating low power methods into the design ofnetwork protocols used for data communication (audio, video, etc.).

Soft-core processors are becoming increasingly common in modern multicoreSoCs. A soft-core processor is a programmable processor that can be synthesizedto a circuit, typically integrated into a larger multicore SoC. Chapter 9 describesarchitecture and design results of a low power Soft-core 32-bit QueueCorearchitecture. This core is an efficient architecture which can be easily programmedand integrated in a multicore SoC platform.

Chapter 10 introduces practical hardware design issues of a multi-mode pro-cessor architecture targeted for embedded applications. In an embodiment of thisprocessor, a single instruction stream consists of two different programmingmodels. This is effectively achieved dynamically with an execution-mode-switching and sources-results computing mechanisms.

Current and future generations of embedded biomedical applications requiremore flexible and cost-effective computing platforms to meet its rapidly growingmarket. The programmable embedded multicore SoC systems appear to be anattractive solution in terms of ease of programming, design cost, power, porta-bility, and time-to-market. The first step toward such complex systems is tocharacterize biomedical applications on the target architecture. Such studies canhelp us understand the design issues and the trade-offs in specializing hardwareand software systems. Chapter 11 ties together previous chapters and presents areal embedded multicore SoC system design targeted for biomedical applications(i.e., ECG processing). For this book, we used our experience to illustrate thecomplete design flow for a multicore SoC running an electrocardiogram (ECG)application in parallel. More specifically, discussions on how to design the algo-rithms, architecture, and register transfer level implementation for ECG process-ing; discussions of the FPGA prototype, and validation are described.

Acknowledgments

The second edition of this book took nearly 3 years to write. It evolved and isderived from our teaching experiences in embedded system designs and archi-tecture to both undergraduate and graduate students. Multicore paradigm created

Preface ix

Page 9: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

stupendous opportunities to increase overall system performance, but also createdmany design challenges that designers must now overcome. Thus, we must con-tinue innovating new algorithms and techniques to solve these challenges. Wemust also continue with our efforts to better educate computer science and com-puter engineering students in both embedded multicore architectures andprogramming.

Abderazek Ben Abdallah

Author Biography

Abderazek Ben Abdallah is currently a Senior Associate Professor in the Schoolof Computer Science and Engineering, the University of Aizu, Japan where he isengaged in advanced computer system research and education. Previously, he wasa Research Associate, then an Assistant Professor at the University of Electro-Communications at Tokyo (2002–2007). He has been a regular visiting Professorat Huazhong University of Science and Technology (HUST), and Hong KongUniversity of Science and Technology (KUST) since 2010. His research interestslie primarily in systems, including embedded real-time systems, energy-efficientsystem design, on-chip interconnection networks, parallel systems, and innovativearchitectures. He participated in new architecture development and led severalmiddle-scale VLSI development efforts on several projects. He received the 2010national prize for outstanding research in the field of computer systems andinformation technology. He has published more than 100 peer-reviewed journaland conference papers, edited one book, wrote one book, and several bookchapters in these areas. He is a member of IEEE, ACM, and IEICE.

x Preface

Page 10: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Contents

1 Introduction to Multicore Systems On-Chip . . . . . . . . . . . . . . . . 11.1 The Multicore Revolution . . . . . . . . . . . . . . . . . . . . . . . . . . 1

1.1.1 Moore’s Law . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21.1.2 On-Chip Interconnection Schemes . . . . . . . . . . . . . 21.1.3 Parallelism and Performance . . . . . . . . . . . . . . . . . 41.1.4 Parallel Hardware Architectures . . . . . . . . . . . . . . . 61.1.5 The Need for Multicore Computing . . . . . . . . . . . . 81.1.6 Multicore SoCs Potential Applications . . . . . . . . . . 8

1.2 Multicore SoC Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.2.1 Programmability Support . . . . . . . . . . . . . . . . . . . . 101.2.2 Software Organization . . . . . . . . . . . . . . . . . . . . . . 121.2.3 Programming Multicore Systems . . . . . . . . . . . . . . 121.2.4 Multicore Implementations. . . . . . . . . . . . . . . . . . . 13

1.3 Multicore SoCs Design Challenges . . . . . . . . . . . . . . . . . . . . 151.3.1 Cache Coherence . . . . . . . . . . . . . . . . . . . . . . . . . 151.3.2 Power and Temperature. . . . . . . . . . . . . . . . . . . . . 161.3.3 Multi-Threading and Memory Management . . . . . . . 161.3.4 Interconnection Networks . . . . . . . . . . . . . . . . . . . 17

1.4 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

2 Multicore SoCs Design Methods . . . . . . . . . . . . . . . . . . . . . . . . . 192.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192.2 Design Space Exploration . . . . . . . . . . . . . . . . . . . . . . . . . . 202.3 Parallel Software Development Phase . . . . . . . . . . . . . . . . . . 22

2.3.1 Compiler-Based Schemes . . . . . . . . . . . . . . . . . . . 222.3.2 Language Extensions Schemes . . . . . . . . . . . . . . . . 232.3.3 Language Extensions with APIs . . . . . . . . . . . . . . . 242.3.4 Model-Based Schemes. . . . . . . . . . . . . . . . . . . . . . 24

2.4 Generic Architecture Template for Real MulticoreSoC Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252.4.1 Target Multicore SoC Platform . . . . . . . . . . . . . . . 252.4.2 Design Method . . . . . . . . . . . . . . . . . . . . . . . . . . . 262.4.3 QueueCore Architecture . . . . . . . . . . . . . . . . . . . . 28

xi

Page 11: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

2.4.4 Performance Analysis . . . . . . . . . . . . . . . . . . . . . . 322.5 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

3 Multicore SoC Organization . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

3.1.1 Heterogeneous MCSoC . . . . . . . . . . . . . . . . . . . . . 383.1.2 Homogeneous MCSoC . . . . . . . . . . . . . . . . . . . . . 413.1.3 Multicore SoC Applications . . . . . . . . . . . . . . . . . . 423.1.4 Applications Mapping . . . . . . . . . . . . . . . . . . . . . . 43

3.2 MCSoC Building Blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . 443.2.1 Processor Core . . . . . . . . . . . . . . . . . . . . . . . . . . . 463.2.2 Memory. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463.2.3 Cache . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483.2.4 Communication Protocols . . . . . . . . . . . . . . . . . . . 483.2.5 Intellectual Property Cores. . . . . . . . . . . . . . . . . . . 503.2.6 IP Cores with Multiple Clock Domains . . . . . . . . . . 513.2.7 Selection of IP Cores . . . . . . . . . . . . . . . . . . . . . . 52

3.3 MCSoC Memory Hierarchy . . . . . . . . . . . . . . . . . . . . . . . . . 533.3.1 Types on On-Chip Memory . . . . . . . . . . . . . . . . . . 543.3.2 Scratchpad Memory . . . . . . . . . . . . . . . . . . . . . . . 563.3.3 Off-Chip Memory . . . . . . . . . . . . . . . . . . . . . . . . . 563.3.4 Memory Power Reduction in SoC Designs . . . . . . . 57

3.4 Memory Consistency in Multicore Systems . . . . . . . . . . . . . . 593.4.1 Cache Coherence Problem . . . . . . . . . . . . . . . . . . . 593.4.2 Cache Coherence Protocols . . . . . . . . . . . . . . . . . . 61

3.5 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63

4 2D Network-on-Chip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 654.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 654.2 2D NoC Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

4.2.1 Topology and Routing. . . . . . . . . . . . . . . . . . . . . . 684.2.2 Switching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 684.2.3 Flow Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . 694.2.4 Arbiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 694.2.5 Network Interface . . . . . . . . . . . . . . . . . . . . . . . . . 69

4.3 2D NoC Hardware Design Details . . . . . . . . . . . . . . . . . . . . 704.3.1 Topology Design . . . . . . . . . . . . . . . . . . . . . . . . . 704.3.2 Pipeline Design . . . . . . . . . . . . . . . . . . . . . . . . . . 714.3.3 Arbiter Design . . . . . . . . . . . . . . . . . . . . . . . . . . . 744.3.4 Crossbar Design . . . . . . . . . . . . . . . . . . . . . . . . . . 754.3.5 Network Interface . . . . . . . . . . . . . . . . . . . . . . . . . 764.3.6 Limitations of Regular Mesh Topology . . . . . . . . . . 774.3.7 SPL Insertion Algorithm . . . . . . . . . . . . . . . . . . . . 784.3.8 Putting it all Together . . . . . . . . . . . . . . . . . . . . . . 83

xii Contents

Page 12: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

4.4 Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 834.4.1 Environments and Parameters. . . . . . . . . . . . . . . . . 834.4.2 Dimension Reversal and Hotspot

Simulation Results . . . . . . . . . . . . . . . . . . . . . . . . 844.4.3 JPEG Encoder Simulation Results . . . . . . . . . . . . . 84

4.5 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88

5 3D Network-on-Chip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 895.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89

5.1.1 Why 3D-NoCs? . . . . . . . . . . . . . . . . . . . . . . . . . . 905.1.2 3D-NoC Versus 2D-NoC . . . . . . . . . . . . . . . . . . . . 925.1.3 Router Architectures . . . . . . . . . . . . . . . . . . . . . . . 935.1.4 Routing Algorithms. . . . . . . . . . . . . . . . . . . . . . . . 93

5.2 Topology Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 955.3 Switching Policy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97

5.3.1 Flit Format Design . . . . . . . . . . . . . . . . . . . . . . . . 985.4 3D-NoC Router Architecture Design. . . . . . . . . . . . . . . . . . . 99

5.4.1 Input-Port Module Design . . . . . . . . . . . . . . . . . . . 1015.4.2 Semi-Adaptive Look-Ahead Routing. . . . . . . . . . . . 1025.4.3 Switch Allocator Design . . . . . . . . . . . . . . . . . . . . 1045.4.4 Stall-Go Flow Control Architecture. . . . . . . . . . . . . 1055.4.5 Matrix-Arbiter Scheduling Architecture . . . . . . . . . . 1065.4.6 Crossbar Design . . . . . . . . . . . . . . . . . . . . . . . . . . 109

5.5 Network Interface Architecture . . . . . . . . . . . . . . . . . . . . . . 1095.6 3D-ONoC Architecture Design Evaluation. . . . . . . . . . . . . . . 113

5.6.1 JPEG Encoder on 3D-ONoC . . . . . . . . . . . . . . . . . 1135.6.2 Matrix Multiplication on 3D-ONoC . . . . . . . . . . . . 1145.6.3 Evaluation Results . . . . . . . . . . . . . . . . . . . . . . . . 1195.6.4 Performance Analysis Evaluation . . . . . . . . . . . . . . 120

5.7 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125

6 Network Interface Architecture and Design for 2D/3D NoCs . . . . 1276.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1276.2 Network Interface Basics. . . . . . . . . . . . . . . . . . . . . . . . . . . 128

6.2.1 Source Routing Network Interface . . . . . . . . . . . . . 1286.2.2 Distributed Routing Network Interface . . . . . . . . . . 129

6.3 Overview of OASIS NoC Architecture . . . . . . . . . . . . . . . . . 1296.4 Architecture, and Design Decision for Distributed

Routing NI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1306.4.1 Network Size Decision . . . . . . . . . . . . . . . . . . . . . 1316.4.2 Packet Size Decision. . . . . . . . . . . . . . . . . . . . . . . 1326.4.3 Buffer Size Decision . . . . . . . . . . . . . . . . . . . . . . . 1326.4.4 Communication Protocol and Flow Control

Decisions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132

Contents xiii

Page 13: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

6.4.5 Packet Format Decision. . . . . . . . . . . . . . . . . . . . . 1326.4.6 Flit-Level Decision . . . . . . . . . . . . . . . . . . . . . . . . 1336.4.7 Summary of all Decisions . . . . . . . . . . . . . . . . . . . 136

6.5 Distributed Routing Network Interface Design . . . . . . . . . . . . 1366.5.1 Core-to-Router (C2R) Buffer . . . . . . . . . . . . . . . . . 1376.5.2 Flitizer Module Architecture . . . . . . . . . . . . . . . . . 1376.5.3 Core-to-Router (C2R) Controller . . . . . . . . . . . . . . 1386.5.4 Router-to-Core (R2C) Buffer . . . . . . . . . . . . . . . . . 1396.5.5 Deflitizer Module Architecture . . . . . . . . . . . . . . . . 1396.5.6 Router-to-Core (R2C) Controller . . . . . . . . . . . . . . 140

6.6 Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1406.6.1 RTL and Gate Level Simulation . . . . . . . . . . . . . . . 1406.6.2 Hardware Prototyping . . . . . . . . . . . . . . . . . . . . . . 1436.6.3 Hardware Complexity . . . . . . . . . . . . . . . . . . . . . . 152

6.7 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152

7 Parallelizing Compiler for Single and Multicore Computing . . . . 1537.1 Instruction Level Parallelism . . . . . . . . . . . . . . . . . . . . . . . . 1537.2 Parallel Queue Compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . 155

7.2.1 Queue Processor Overview . . . . . . . . . . . . . . . . . . 1557.2.2 Compiling for 1-Offset QueueCore

Instruction Set . . . . . . . . . . . . . . . . . . . . . . . . . . . 1567.3 Parallelizing Compiler Framework . . . . . . . . . . . . . . . . . . . . 158

7.3.1 1-Offset P-Code Generation Phase . . . . . . . . . . . . . 1597.3.2 Offset Calculation Phase . . . . . . . . . . . . . . . . . . . . 1637.3.3 Instruction Scheduling Phase . . . . . . . . . . . . . . . . . 1647.3.4 Natural Instruction Level Parallelism Extraction:

Statement Merging Transformation . . . . . . . . . . . . . 1657.3.5 Assembly Generation Phase . . . . . . . . . . . . . . . . . . 167

7.4 Parallelizing Compiler Development Results . . . . . . . . . . . . . 1697.4.1 Queue Compiler Evaluation . . . . . . . . . . . . . . . . . . 1697.4.2 Comparison of Generated QueueCore Code

with Optimized RISC Code . . . . . . . . . . . . . . . . . . 1717.5 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173

8 Power Optimization Techniques for Multicore SoCs . . . . . . . . . . 1758.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1758.2 Power Aware Technological-Level Design Optimizations . . . . 177

8.2.1 Factors Affecting CMOS Power Consumption . . . . . 1778.2.2 Reducing Voltage and Frequency . . . . . . . . . . . . . . 1788.2.3 Reducing Capacitance . . . . . . . . . . . . . . . . . . . . . . 179

8.3 Power Aware Logic-Level Design Optimizations . . . . . . . . . . 1808.3.1 Clock Gating . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1808.3.2 Logic Encoding . . . . . . . . . . . . . . . . . . . . . . . . . . 181

xiv Contents

Page 14: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

8.3.3 Data Guarding . . . . . . . . . . . . . . . . . . . . . . . . . . . 1828.4 Power-Aware System Level Design Optimizations . . . . . . . . . 183

8.4.1 Hardware System Architecture PowerConsumption Optimizations . . . . . . . . . . . . . . . . . . 183

8.4.2 Operating System Power ConsumptionOptimization . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186

8.4.3 Application, Compilation Techniquesand Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . 188

8.4.4 Energy Reduction in Network Protocols . . . . . . . . . 1898.5 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193

9 Soft-Core Processor for Low-Power EmbeddedMulticore SoCs. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1959.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1959.2 Produced Order Queue Computing Overview. . . . . . . . . . . . . 1979.3 QC-2 Core Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . 199

9.3.1 Instruction Set Design Considerations . . . . . . . . . . . 1999.3.2 Instruction Pipeline Structure . . . . . . . . . . . . . . . . . 2009.3.3 Dynamic Operands Addresses Calculation . . . . . . . . 2029.3.4 QC-2 FPA Organization . . . . . . . . . . . . . . . . . . . . 2039.3.5 Circular Queue-Register Structure. . . . . . . . . . . . . . 206

9.4 Synthesis of the QC-2 Core . . . . . . . . . . . . . . . . . . . . . . . . . 2079.4.1 Design Approach . . . . . . . . . . . . . . . . . . . . . . . . . 207

9.5 Results and Discussions . . . . . . . . . . . . . . . . . . . . . . . . . . . 2099.5.1 Execution Speedup and Code Analysis . . . . . . . . . . 2099.5.2 Synthesis Results . . . . . . . . . . . . . . . . . . . . . . . . . 2109.5.3 Speed and Power Consumption Comparison

with Synthesizable CPU Cores . . . . . . . . . . . . . . . . 2129.6 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213

10 Dual-Execution Processor Architecture for EmbeddedComputing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21510.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21510.2 System Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217

10.2.1 Pipeline Structure . . . . . . . . . . . . . . . . . . . . . . . . . 21910.2.2 Fetch Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21910.2.3 Decode Unit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21910.2.4 Dynamic Switching Mechanism . . . . . . . . . . . . . . . 22110.2.5 Calculation of Produced and Consumed Data. . . . . . 22110.2.6 Queue-Stack Computation Unit . . . . . . . . . . . . . . . 22210.2.7 Sources-Results Computing Mechanism . . . . . . . . . 22410.2.8 Issue Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22610.2.9 Execution Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . 22710.2.10 Shared Storage Mechanism . . . . . . . . . . . . . . . . . . 229

Contents xv

Page 15: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

10.2.11 Covop Instruction Execution Mechanism. . . . . . . . . 22910.2.12 Interrupt Handling Mechanism . . . . . . . . . . . . . . . . 229

10.3 Sub-Routine Call Handling Mechanism. . . . . . . . . . . . . . . . . 23310.4 Hardware Design and Evaluation Results . . . . . . . . . . . . . . . 236

10.4.1 DEP System Pipeline Control. . . . . . . . . . . . . . . . . 23710.4.2 Hardware Design Result . . . . . . . . . . . . . . . . . . . . 23810.4.3 Comparison Results . . . . . . . . . . . . . . . . . . . . . . . 241

10.5 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242

11 Case Study: Deign of Embedded Multicore SoCfor Biomedical Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24311.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243

11.1.1 Electrocardiography and Heart Diseases . . . . . . . . . 24411.2 Digital Signal Processing. . . . . . . . . . . . . . . . . . . . . . . . . . . 246

11.2.1 Analog and Digital Signals . . . . . . . . . . . . . . . . . . 24611.2.2 Signal Processing . . . . . . . . . . . . . . . . . . . . . . . . . 24611.2.3 Analog to Digital Conversion. . . . . . . . . . . . . . . . . 247

11.3 Period-Peak Detection Algorithm . . . . . . . . . . . . . . . . . . . . . 24811.3.1 Period Detection . . . . . . . . . . . . . . . . . . . . . . . . . . 24811.3.2 Peaks Detection . . . . . . . . . . . . . . . . . . . . . . . . . . 249

11.4 Multicore SoC Architecture and Hardware Design . . . . . . . . . 25011.4.1 Signal Reading . . . . . . . . . . . . . . . . . . . . . . . . . . . 25111.4.2 Filtering. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25311.4.3 Data Processing . . . . . . . . . . . . . . . . . . . . . . . . . . 25511.4.4 Processor Core . . . . . . . . . . . . . . . . . . . . . . . . . . . 256

11.5 Real-Time Interaction Interface Development . . . . . . . . . . . . 25711.5.1 Data Capturing . . . . . . . . . . . . . . . . . . . . . . . . . . . 25711.5.2 Data Display and Analysis . . . . . . . . . . . . . . . . . . . 259

11.6 Design Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25911.6.1 Hardware Complexity . . . . . . . . . . . . . . . . . . . . . . 25911.6.2 Performance Evaluation. . . . . . . . . . . . . . . . . . . . . 260

11.7 Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261

References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263

xvi Contents

Page 16: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Figures

Fig. 1.1 Scaling of transistor count and operating frequency in ICs.The feature size and design abstraction are also shown . . . . . 3

Fig. 1.2 Different ways for exploiting parallelism over various systemorganization: a Single core, b Multicore with separatecaches, c Multicore with shared cache, d Multicore withsimultaneous threading, e Multiprocessor . . . . . . . . . . . . . . . 6

Fig. 1.3 From PCB to MCSoC . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7Fig. 1.4 Multicore SoC potential applications . . . . . . . . . . . . . . . . . . 9Fig. 1.5 Typical multicore SoC architectural view. . . . . . . . . . . . . . . 10Fig. 1.6 Software layers on top of the hardware . . . . . . . . . . . . . . . . 11Fig. 1.7 Sample OpenMP code using section and parallel directives:

a Functional decomposition, b Data decomposition. . . . . . . . 13Fig. 1.8 Heterogeneous multicore CELL organization . . . . . . . . . . . . 14Fig. 2.1 SoC typical architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . 21Fig. 2.2 Compiler based scheme . . . . . . . . . . . . . . . . . . . . . . . . . . . 22Fig. 2.3 Parallel for loop with OpenMP . . . . . . . . . . . . . . . . . . . . . . 24Fig. 2.4 Multicore SoC system platform. This is a typical instance

of the architecture, where the addition of a new corewill not change the principle of the methodology . . . . . . . . . 26

Fig. 2.5 Linked-task design flow graph (DFG). a Hardware relatedtasks, b Application related tasks . . . . . . . . . . . . . . . . . . . . 27

Fig. 2.6 Next QH and QT pointers calculation mechanism. . . . . . . . . 29Fig. 2.7 QC-2’s source 2 address calculation . . . . . . . . . . . . . . . . . . 30Fig. 2.8 QC-2’s FADD hardware . . . . . . . . . . . . . . . . . . . . . . . . . . 31Fig. 2.9 QC-2’s FMUL hardware . . . . . . . . . . . . . . . . . . . . . . . . . . 33Fig. 2.10 Resource usage and timing for 256*33 bit QREG unit

for different coding and optimization strategies . . . . . . . . . . 34Fig. 2.11 Achievable frequency is the instruction throughput

for hardware implementations of the QC-2 processor . . . . . . 35Fig. 3.1 General organization view of a modern typical MCSoC . . . . 39Fig. 3.2 Example of an embedded multicore system for a typical

digital still camera. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

xvii

Page 17: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 3.3 Example of MPEG-2 encoder for a heterogeneousMCSoC system. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

Fig. 3.4 Heterogeneous MCSoC organization example. . . . . . . . . . . . 41Fig. 3.5 Homogeneous MCSoC organization example . . . . . . . . . . . . 41Fig. 3.6 Example of MCSoC application in wireless communication:

Lucent Daytona MCSoC . . . . . . . . . . . . . . . . . . . . . . . . . . 43Fig. 3.7 Simplified view of a typical MCSoC architecture

with different core and memory types . . . . . . . . . . . . . . . . . 45Fig. 3.8 State of the art MCSoC architecture based

on network-on-chip paradigm . . . . . . . . . . . . . . . . . . . . . . . 45Fig. 3.9 Typical 5 pipeline stages of a RISC processor core. . . . . . . . 46Fig. 3.10 Example of MCSoC with single external DRAM memory . . . 47Fig. 3.11 Cache organization in a single node of a typical MCSoC . . . 48Fig. 3.12 Evolution of On-Chip communication interconnect . . . . . . . . 49Fig. 3.13 Open Core Protocol (OCP) and Network Protocol (NP)

interfacing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50Fig. 3.14 NoC operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51Fig. 3.15 Intellectual property example . . . . . . . . . . . . . . . . . . . . . . . 52Fig. 3.16 Three Clock Domains MCSoC . . . . . . . . . . . . . . . . . . . . . . 52Fig. 3.17 Example of mapping of an MPEG-2 decoder. a Using

two cores, b Using three cores . . . . . . . . . . . . . . . . . . . . . . 54Fig. 3.18 Simplified view of a MCSoC architecture having

different memories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Fig. 3.19 Example of four cores communicating via FIFOs . . . . . . . . . 56Fig. 3.20 MCSoC memory subsystem with SPARM

(only interconnection for one node is shownfor simplicity). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

Fig. 3.21 Projection of memory/logic compositionof power-constrained SoC chips [ITRS (2003)]. . . . . . . . . . . 58

Fig. 3.22 Direct-mapped cache organization. . . . . . . . . . . . . . . . . . . . 60Fig. 3.23 Cache coherence problem example without coherence

protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61Fig. 4.1 Typical paradigms: a circuit switching,

b packet switching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66Fig. 4.2 Typical standard topology: a N 9 M mesh topology,

b 3 stage Clos topology . . . . . . . . . . . . . . . . . . . . . . . . . . . 67Fig. 4.3 Typical customized topology . . . . . . . . . . . . . . . . . . . . . . . 67Fig. 4.4 3� 3 NoC based on mesh topology. S switch, PE processing

element, NI network interface. . . . . . . . . . . . . . . . . . . . . . . 68Fig. 4.5 External connections to one router . . . . . . . . . . . . . . . . . . . 71Fig. 4.6 4 9 4 mesh topology. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71Fig. 4.7 ONoC router block diagram . . . . . . . . . . . . . . . . . . . . . . . . 72Fig. 4.8 Matrix arbitration example . . . . . . . . . . . . . . . . . . . . . . . . . 74

xviii Figures

Page 18: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 4.9 Stall-go block diagram. . . . . . . . . . . . . . . . . . . . . . . . . . . . 75Fig. 4.10 a State machine design. b Nearly full signal output . . . . . . . 76Fig. 4.11 Arbiter control signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75Fig. 4.12 Sample transmitter NI block diagram . . . . . . . . . . . . . . . . . 77Fig. 4.13 Sample receiver NI block diagram . . . . . . . . . . . . . . . . . . . 77Fig. 4.14 Flit structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77Fig. 4.15 JPEG encoder packet transmission patterns . . . . . . . . . . . . . 78Fig. 4.16 Short-Path-Link (SPL) insertion example . . . . . . . . . . . . . . . 79Fig. 4.17 SPL insertion algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . 80Fig. 4.18 Extra-Port insertion. a Receiver. b Transmitter . . . . . . . . . . . 81Fig. 4.19 Dimension reversal with 2 SPLs . . . . . . . . . . . . . . . . . . . . . 82Fig. 4.20 Hotspot with 2 SPL. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82Fig. 4.21 JPEG encoder with 3 SPL . . . . . . . . . . . . . . . . . . . . . . . . . 82Fig. 4.22 The top module of designed circuit with file names . . . . . . . 83Fig. 4.23 Router top module with file names . . . . . . . . . . . . . . . . . . . 84Fig. 4.24 ONoC with JPEG encoder file hierarchy . . . . . . . . . . . . . . . 85Fig. 4.25 Dimension reversal simulation result . . . . . . . . . . . . . . . . . . 87Fig. 4.26 Hotspot simulation result . . . . . . . . . . . . . . . . . . . . . . . . . . 87Fig. 4.27 JPEG encoder simulation result . . . . . . . . . . . . . . . . . . . . . 88Fig. 5.1 SoC interconnection types: a Shared bus,

b Point-2-Point, c NoC . . . . . . . . . . . . . . . . . . . . . . . . . . . 90Fig. 5.2 Configuration example of a 4 9 4 9 4 3D-ONoC

based on mesh topology. . . . . . . . . . . . . . . . . . . . . . . . . . . 96Fig. 5.3 3D-ONOC flit format . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98Fig. 5.4 3D-ONoC pipeline stages: Buffer writing (BW), Routing

Calculation and Switch Allocation (RC/SA) and CrossbarTraversal stage (CT) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100

Fig. 5.5 Input-port module architecture . . . . . . . . . . . . . . . . . . . . . . 101Fig. 5.6 Switch allocator architecture. . . . . . . . . . . . . . . . . . . . . . . . 104Fig. 5.7 Stall-Go flow control mechanism . . . . . . . . . . . . . . . . . . . . 106Fig. 5.8 Stall-Go flow control finite state machine . . . . . . . . . . . . . . 106Fig. 5.9 Scheduling-matrix priority assignment . . . . . . . . . . . . . . . . . 107Fig. 5.10 Crossbar circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109Fig. 5.11 Network interface architecture: transmitter side . . . . . . . . . . 111Fig. 5.12 Network interface architecture: receiver side . . . . . . . . . . . . 111Fig. 5.13 Task graph of the JPEG encoder. . . . . . . . . . . . . . . . . . . . . 114Fig. 5.14 Extended task graph of the JPEG encoder . . . . . . . . . . . . . . 115Fig. 5.15 JPEG encoder mapped on 2 9 4 2D-ONoC . . . . . . . . . . . . . 115Fig. 5.16 JPEG encoder mapped on: 2 9 2 9 2 3D-ONoC . . . . . . . . . 116Fig. 5.17 Matrix multiplication example: the multiplication of an ixk

matrix A by a kxj matrix B results in an ixj matrix R . . . . . . 116Fig. 5.18 Simple example demonstrating the matrix multiplication

calculation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116

Figures xix

Page 19: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 5.19 3�3 matrix multiplication using (a) optimistic and(b) pessimistic mapping approaches . . . . . . . . . . . . . . . . . . 118

Fig. 5.20 Execution time comparison between 3D and 2D ONoC. . . . . 120Fig. 5.21 Average number of hops comparison for both pessimistic

and optimistic mapping on 3 9 3 network size. . . . . . . . . . . 122Fig. 5.22 Average number of hops comparison for both pessimistic

and optimistic mapping on 4 9 4 network size. . . . . . . . . . . 122Fig. 5.23 Average number of hops comparison for both pessimistic

and optimistic mapping on 6 9 6 network size. . . . . . . . . . . 122Fig. 5.24 Stall average count comparison between 3D

and 2D ONoC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123Fig. 5.25 Stall average count comparison between 3D and 2D ONoC

with different traffic loads . . . . . . . . . . . . . . . . . . . . . . . . . 124Fig. 5.26 Execution time comparison between 3D and 2D ONoC

with different traffic loads . . . . . . . . . . . . . . . . . . . . . . . . . 124Fig. 6.1 Network interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128Fig. 6.2 One router data-path . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130Fig. 6.3 4 9 4 OASIS NoC mesh topology . . . . . . . . . . . . . . . . . . . 130Fig. 6.4 Distributed routing NI architecture block diagram. . . . . . . . . 131Fig. 6.5 Packet format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133Fig. 6.6 Packet HEADER format . . . . . . . . . . . . . . . . . . . . . . . . . . 133Fig. 6.7 BODY and END format . . . . . . . . . . . . . . . . . . . . . . . . . . 133Fig. 6.8 HEADER flit format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134Fig. 6.9 BODY flit format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135Fig. 6.10 END flit format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135Fig. 6.11 Format of packet header after deflitization . . . . . . . . . . . . . . 135Fig. 6.12 Format of BODY/END flits after deflitization . . . . . . . . . . . 136Fig. 6.13 Internal structure of NI for distributed routing . . . . . . . . . . . 136Fig. 6.14 C2R-Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137Fig. 6.15 Flitizer module architecture . . . . . . . . . . . . . . . . . . . . . . . . 138Fig. 6.16 Core-to-Router (C2R) controller architecture . . . . . . . . . . . . 138Fig. 6.17 Router-to-Core (R2C) buffer . . . . . . . . . . . . . . . . . . . . . . . 139Fig. 6.18 Deflitizer module architecture. . . . . . . . . . . . . . . . . . . . . . . 140Fig. 6.19 R2C Controller module architecture . . . . . . . . . . . . . . . . . . 141Fig. 6.20 RTL View of C2R module. . . . . . . . . . . . . . . . . . . . . . . . . 141Fig. 6.21 Wave form of RTL simulation for C2R . . . . . . . . . . . . . . . . 142Fig. 6.22 RTL view of R2C module . . . . . . . . . . . . . . . . . . . . . . . . . 142Fig. 6.23 Wave form of RTL simulation for R2C . . . . . . . . . . . . . . . . 142Fig. 6.24 Waveform of gate level simulation for C2R . . . . . . . . . . . . . 143Fig. 6.25 Waveform of gate level simulation for R2C . . . . . . . . . . . . . 143Fig. 6.26 Nios II system architecture. . . . . . . . . . . . . . . . . . . . . . . . . 144Fig. 6.27 C2R architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144Fig. 6.28 Single-packet to single-flit . . . . . . . . . . . . . . . . . . . . . . . . . 145

xx Figures

Page 20: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 6.29 Packet HEADER to flit HEADER . . . . . . . . . . . . . . . . . . . 145Fig. 6.30 Packet BODY to flit BODY. . . . . . . . . . . . . . . . . . . . . . . . 146Fig. 6.31 Packet END to flit END . . . . . . . . . . . . . . . . . . . . . . . . . . 146Fig. 6.32 Router to core architecture . . . . . . . . . . . . . . . . . . . . . . . . . 147Fig. 6.33 Single-flit to single-packet . . . . . . . . . . . . . . . . . . . . . . . . . 147Fig. 6.34 Flit HEADER to packet HEADER . . . . . . . . . . . . . . . . . . . 147Fig. 6.35 Flit BODY to packet BODY . . . . . . . . . . . . . . . . . . . . . . . 148Fig. 6.36 Flit END to packet END . . . . . . . . . . . . . . . . . . . . . . . . . . 148Fig. 6.37 Core to core architecture . . . . . . . . . . . . . . . . . . . . . . . . . . 149Fig. 6.38 Nios II core to dummy memory RTL view . . . . . . . . . . . . . 149Fig. 6.39 RTL view of the dummy memory to Nios II core module . . . 149Fig. 6.40 Core-Memory: single packet. . . . . . . . . . . . . . . . . . . . . . . . 150Fig. 6.41 Core-memory: packet HEADER . . . . . . . . . . . . . . . . . . . . . 150Fig. 6.42 Core-memory: packet BODY . . . . . . . . . . . . . . . . . . . . . . . 151Fig. 6.43 Core-memory: packet END . . . . . . . . . . . . . . . . . . . . . . . . 151Fig. 7.1 Instruction sequence generation from the parse tree

of expression x ¼ aþbb�c. a Parse tree. b Instruction

sequence. c QSTATEs . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157Fig. 7.2 Instruction sequence generation from DAG of expression

x ¼ aþbb�c. a DAG. b Instruction sequence. c QSTATEs . . . . . . 158

Fig. 7.3 Parallelizing compiler infrastructure . . . . . . . . . . . . . . . . . . 160Fig. 7.4 QIR code fragment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165Fig. 7.5 Statement merging transformation . . . . . . . . . . . . . . . . . . . . 166Fig. 7.6 Assembly output for QueueCore processor a Original

QueueCore assembly code b ILP exposed for QueueCoreassembly processor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168

Fig. 7.7 Effect on ILP of statement merging transformationin the queue compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170

Fig. 7.8 Instruction level parallelism improvement of queuecompiler over optimizing compiler for a RISC machine . . . . 172

Fig. 7.9 Normalized code size for two embedded RISC processorsand QueueCore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172

Fig. 8.1 Clock gating example: a conventional, b gated clock . . . . . . 181Fig. 8.2 Dual Operation ALU with Guard Logic . . . . . . . . . . . . . . . . 182Fig. 8.3 Power consumption in typical processor . . . . . . . . . . . . . . . 186Fig. 8.4 Protocol stack of a generic wireless network,

and corresponding areas of energy efficientpossible research . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191

Fig. 9.1 Sample data flow graph and queue-register contents for theexpressions: e ¼ ab=c and f ¼ abðcþ dÞ. a Original sampleprogram. b Translated (augmented) sample program.c Generated instructions sequence. d Circular queue-registercontent at each execution state . . . . . . . . . . . . . . . . . . . . . . 198

Figures xxi

Page 21: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 9.2 QC-2 instruction format and computing examples: a addinstruction, b mod instruction, c load immediate (ldil)instruction, d call instruction, and e store word(stw) instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199

Fig. 9.3 QC-2 architecture block diagram. During RTL description,the core is broken into small and manageable modulesusing modular approach structure for easy verification,debugging and modification . . . . . . . . . . . . . . . . . . . . . . . . 201

Fig. 9.4 Source 1 (source1)address calculation hardware . . . . . . . . . . 202Fig. 9.5 Source 2 (source2)) address calculation hardware . . . . . . . . . 203Fig. 9.6 QC-2’s FPA hardware: adder circuit . . . . . . . . . . . . . . . . . . 204Fig. 9.7 QC-2’s FPA hardware: multiplier circuit . . . . . . . . . . . . . . . 205Fig. 9.8 Finite state machine transition for QC-2 pipeline

synchronization. The following conditions are evaluated:next stage can accept data (ACP), previous pipeline stagecan supply data (SUP), last cycle of computation (CPT) . . . . 206

Fig. 9.9 Circular queue-register (QREG) structure. a initialQREG state; b QREG state after writing the first32 bit data (dat1); c QREG state after writing thesecond data (dat2) and consuming the first 32 bit data(dat1); d QREG state with LQH pointer updateand different regions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207

Fig. 9.10 Achievable frequency is the instruction throughputfor hardware implementations of the QC-2 processor.Simulation speeds have been converted to a nominalfrequency rating to facilitate comparison . . . . . . . . . . . . . . . 211

Fig. 9.11 Resource usage and timing for 256*33 bit QREG unitfor different coding and optimization strategies . . . . . . . . . . 212

Fig. 10.1 DEP architecture block diagram . . . . . . . . . . . . . . . . . . . . . 218Fig. 10.2 Block diagram of fetch unit . . . . . . . . . . . . . . . . . . . . . . . . 220Fig. 10.3 Block diagram of decode unit. . . . . . . . . . . . . . . . . . . . . . . 220Fig. 10.4 Mode-switching mechanism . . . . . . . . . . . . . . . . . . . . . . . . 221Fig. 10.5 Decode mechanism: a decode for queue program

and b decode for stack program . . . . . . . . . . . . . . . . . . . . . 223Fig. 10.6 Block diagram of queue-stack computation unit . . . . . . . . . . 223Fig. 10.7 Address calculation mechanism for sources

and destination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224Fig. 10.8 Address calculation mechanism for next instruction’s

source1 and destination . . . . . . . . . . . . . . . . . . . . . . . . . . . 225Fig. 10.9 Addresses calculation example: a QEM mode

and b SEM mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227Fig. 10.10 Block diagram of the issue unit . . . . . . . . . . . . . . . . . . . . . 228Fig. 10.11 Block diagram of execution unit . . . . . . . . . . . . . . . . . . . . . 228Fig. 10.12 Block diagram of shared storage unit . . . . . . . . . . . . . . . . . 229

xxii Figures

Page 22: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Fig. 10.13 Address extension mechanism . . . . . . . . . . . . . . . . . . . . . . 230Fig. 10.14 Components used for software interrupt handling

mechanism in DEP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230Fig. 10.15 Queue status when interrupt occur and return from interrupt.

a Queue status before interrupt, b when interrupt occur,c Queue: ready for interrupt handler, d Queue:when return from interrupt . . . . . . . . . . . . . . . . . . . . . . . . . 231

Fig. 10.16 Stack status when interrupt occur and return from interrupt.a stack status before interrupt, b when interrupt occur,c stcak: ready for interrupt handler, d stcak: when returnfrom interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232

Fig. 10.17 Components used for subroutine call mechanism in DEP. . . . 233Fig. 10.18 Queue status when subroutine call and return from call.

a queue status before call, b when execute the call, c queue:ready for handle callee program, d when execute the returnfrom call (rfc) instruction, and e queue: when return fromcall with return result . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234

Fig. 10.19 Stack status when subroutine call and return from call.a stack status before call, b when execute the call, c stack:ready for handle callee program, d when execute the returnfrom call (rfc) instruction, and e stack: when return fromcall with return result . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235

Fig. 10.20 Finite state machine transition for DEP pipelinesynchronization. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237

Fig. 10.21 Critical path for different units . . . . . . . . . . . . . . . . . . . . . . 238Fig. 11.1 A typical ECG wave . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245Fig. 11.2 PPD algorithm processing flow. . . . . . . . . . . . . . . . . . . . . . 248Fig. 11.3 Period detection computation details . . . . . . . . . . . . . . . . . . 250Fig. 11.4 Peaks detection computation details . . . . . . . . . . . . . . . . . . 250Fig. 11.5 Period detection: finding maximum value algorithm.

The autocorrelation step (ACF_STEP is set . . . . . . . . . . . . . 251Fig. 11.6 Period detection: reduce negative value algorithm. . . . . . . . . 251Fig. 11.7 Period detection: find base points . . . . . . . . . . . . . . . . . . . . 252Fig. 11.8 Period detection: sort base points . . . . . . . . . . . . . . . . . . . . 252Fig. 11.9 High-level view of the BANSMOM system architecture.

a Signal reading, b filtering, c analysis, d display. . . . . . . . . 253Fig. 11.10 Prototyped multicore SoC block diagram . . . . . . . . . . . . . . . 254Fig. 11.11 Nios II core architecture block diagram . . . . . . . . . . . . . . . . 254Fig. 11.12 Software simulation output. . . . . . . . . . . . . . . . . . . . . . . . . 256Fig. 11.13 a Get live-data, b Get previous-data . . . . . . . . . . . . . . . . . . 258Fig. 11.14 Multicore SoC system running snapshot . . . . . . . . . . . . . . . 259Fig. 11.15 Interactive RTI tool displaying ECG waves . . . . . . . . . . . . . 260

Figures xxiii

Page 23: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Tables

Table 2.1 Linked-task description . . . . . . . . . . . . . . . . . . . . . . . . . . . 27Table 2.2 QC-2 processor design results: modules

complexity as LE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34Table 3.1 Cache coherence states . . . . . . . . . . . . . . . . . . . . . . . . . . . 62Table 4.1 Area utilization for a 5-ports router . . . . . . . . . . . . . . . . . . 80Table 4.2 Area utilization for 6-port router . . . . . . . . . . . . . . . . . . . . 80Table 4.3 Dimension reversal simulation environment. . . . . . . . . . . . . 85Table 4.4 Hotspot simulation environment . . . . . . . . . . . . . . . . . . . . . 86Table 4.5 JPEG encoder simulation environment . . . . . . . . . . . . . . . . 86Table 4.6 Hardware complexity: Dimension reversal. . . . . . . . . . . . . . 86Table 4.7 Hardware complexity: Hotspot . . . . . . . . . . . . . . . . . . . . . . 86Table 4.8 Hardware complexity: JPEG encoder . . . . . . . . . . . . . . . . . 88Table 5.1 Simulation parameters. . . . . . . . . . . . . . . . . . . . . . . . . . . . 119Table 5.2 3D-ONoC hardware complexity compared

with 2D-ONoC. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119Table 6.1 Flit types and coding . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134Table 6.2 Summary of decisions for distributed routing NI . . . . . . . . . 136Table 6.3 Hardware complexity . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152Table 7.1 Lines of C code for each phase of the queue compiler’s

back-end . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169Table 7.2 Instruction category percentages for the compiled

benchmarks for the QueueCore . . . . . . . . . . . . . . . . . . . . . 170Table 7.3 QueueCore’s program maximum offset reference value . . . . 171Table 8.1 Operating system functionality and corresponding

techniques for optimizing energy utilization . . . . . . . . . . . . 187Table 9.1 Normalized code sizes for various benchmark programs

over different target architectures . . . . . . . . . . . . . . . . . . . . 209Table 9.2 Execution time and speedup results . . . . . . . . . . . . . . . . . . 210Table 9.3 QC-2 Hardware configuration parameters . . . . . . . . . . . . . . 210

xxv

Page 24: Atlantis Ambient and Pervasive Intelligence - Springer978-94-91216-92-3/1.pdf · The book series ‘Atlantis Ambient and Pervasive Intelligence ... in multicore architecture today

Table 9.4 QC-2 processor design results: modules complexity as LE(logic elements) and TCF (total combinational functions)when synthesized for FPGAs (with Stratix device)and Structured ASIC (HardCopy II) families . . . . . . . . . . . . 211

Table 9.5 Speed and power consumption comparisons for variousSynthesizable CPU cores over speed (SPD) and area(ARA) optimizations. This evaluation was performedunder the following constraints: (1) Family: Stratix;(2) Device: EP1S25F1020; (3) Speed: C6. The speedis given in MHz . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213

Table 10.1 PN and CN calculation with instruction in decode stage.PN means number of produced data and CN meansnumber of consumed data . . . . . . . . . . . . . . . . . . . . . . . . . 222

Table 10.2 DEP Processor hardware configuration parameters . . . . . . . . 239Table 10.3 Verilog HDL code size for integrated DEP processor . . . . . . 239Table 10.4 Synthesis results. LEs means Logic Elements. AOP means

Area optimization and SOP means speed optimization . . . . . 240Table 10.5 Comparison results between DEP and PQP architecture.

Area in LE, Speed in MHz, and Power in mW . . . . . . . . . . 240Table 10.6 DEP speed comparisons . . . . . . . . . . . . . . . . . . . . . . . . . . 241Table 10.7 DEP power consumption comparisons with various

synthesizable CPU cores . . . . . . . . . . . . . . . . . . . . . . . . . . 241Table 11.1 Hardware complexity . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260Table 11.2 Performance evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . 261

xxvi Tables