Скачать презентацию Hardware-Software Codesign Elvira Kitsis Hermawan Ho Alex Papadimoulis Скачать презентацию Hardware-Software Codesign Elvira Kitsis Hermawan Ho Alex Papadimoulis

56680723421bed27e4ea184f682e4a12.ppt

  • Количество слайдов: 40

Hardware-Software Codesign Elvira Kitsis Hermawan Ho Alex Papadimoulis Hardware-Software Codesign Elvira Kitsis Hermawan Ho Alex Papadimoulis

HW/SW Codesign Introduction n n Unified design of hardware and software systems All design HW/SW Codesign Introduction n n Unified design of hardware and software systems All design based off of logical model n n no HW/SW partition Maintained throughout design process Concurrent Design hw/sw optimized for peak performance

HW/SW Codesign Origins n n n Field of Embedded systems Demand for consumer information HW/SW Codesign Origins n n n Field of Embedded systems Demand for consumer information appliances (cell phone, pda) Specialized industrial products designers developed new tools and techniques to satisfy demand These became HW/SW codesign

Traditional Systems Design n n Early, key decision: HW/SW Partition Must be kept, changes Traditional Systems Design n n Early, key decision: HW/SW Partition Must be kept, changes require extensive redesign for both HW and SW Lacks a well defined HW/SW interface data flow Leads to Sub optimal designs And longer design-to-market time

HW/SW Codesign - A Solution n n HW/SW Codesign alleviates traditional design issues Maps HW/SW Codesign - A Solution n n HW/SW Codesign alleviates traditional design issues Maps system specification to a mixed HW/SW implementation n n Conventional SW on a RISC processor ASICs (Application Specific Integrated Circuit)

Practical Implementation of Hardware Software Codesign n Elvira Kitsis Practical Implementation of Hardware Software Codesign n Elvira Kitsis

Practical implementation of hardware/software co-design n n The purpose of hardware/software co-design Four common Practical implementation of hardware/software co-design n n The purpose of hardware/software co-design Four common approaches to the task of hardware/software co-design · · unbiased hardware-biased software-biased hardware acceleration

Co-design development routine n n Objectives of development routine The first stage is to Co-design development routine n n Objectives of development routine The first stage is to determine the performance critical section of a C program using a profiler tool and routine system, as described in Fig. 1.

Next step n The next step in the development routine is to implement a Next step n The next step in the development routine is to implement a critical section in hardware as shown in Fig. 2.

Limitations on the type C code: n n n All C types must be Limitations on the type C code: n n n All C types must be mapped to 16/32 bit signed integers in Hardware. C Type qualifiers, enumerated types, unions and structures NOT permited Global variables are NOT allowed Parameters for functions may consists of simple types, pointer types and data arrays only. No support for "gotos"

Test Results Execution time Example 1 Software-only Software-hardware 80 ms 47 ms Example 2 Test Results Execution time Example 1 Software-only Software-hardware 80 ms 47 ms Example 2 Software-only Software-hardware 114 ms 80 ms

Hardware or software? n n n Performance Cost Form factor Flexibility Safety Architectural cleanness Hardware or software? n n n Performance Cost Form factor Flexibility Safety Architectural cleanness and simplicity

System Level Memory Optimization for Hardware. Software Co-Design Hermawan Ho System Level Memory Optimization for Hardware. Software Co-Design Hermawan Ho

Intro n n n In multi media applications, a considerable amount of memory is Intro n n n In multi media applications, a considerable amount of memory is required. To reduce this dominant cost. A quad-tree based image coding application.

Design Model n n If we do not need the flexibility, one or more Design Model n n If we do not need the flexibility, one or more dedicated hardware processor(s) can be designed to perform the functions which are in the cycle. When the flexibility is needed, we can use data level parallelism. The advantage of this approach is that it is simple to program but the memory overhead is high.

Design Model n n n Alternatively, we can use task level parallelism. The advantages Design Model n n n Alternatively, we can use task level parallelism. The advantages are that the code size per processor is relatively low. The disadvantage is that the design time will be much higher due to the complex processor partitioning and memory management.

System Level Memory Optimization n All functions are taken together in one big function. System Level Memory Optimization n All functions are taken together in one big function. We have an algorithm that operates block per block. All computations are done on the first block. Buffer memory for only one block will be required between the sub modules.

QSDPCM n n n QSDPCM (Quadtree Structured Difference Pulse Code Modulation) is a compression QSDPCM n n n QSDPCM (Quadtree Structured Difference Pulse Code Modulation) is a compression technique for video. The algorithm optimize both the displacement vector and the quadtree mean decomposition jointly. The displacement which requires the minimum number of bits for the quadtree decomposition is selected

Summary n n If the HW/SW partitioning is performed first, remaining buffers afterwards cannot Summary n n If the HW/SW partitioning is performed first, remaining buffers afterwards cannot be optimized away anymore. QSDPCM application, can do much better before the HW/SW partitioning.

The Design of Mixed Hardware/Software Systems The Design of Mixed Hardware/Software Systems

Mixed Hardware/Software Systems n n n Many digital systems contain both hardware and software Mixed Hardware/Software Systems n n n Many digital systems contain both hardware and software Combining hardware and software design tasks has several advantages. One is that may accelerate the design process. Another is that may enable hardware/software trade-offs to be made dynamically, as the design progresses.

Mixed Hardware/Software Systems n n Unless they are design together, we do not think Mixed Hardware/Software Systems n n Unless they are design together, we do not think of it as a mixed hardware/software system. The distinguishing factor is whether the boundary between hardware and software is logical boundary or a physical boundary.

Simulation of Hardware/Software Systems n n Presents the problem of modeling the behavior of Simulation of Hardware/Software Systems n n Presents the problem of modeling the behavior of a system based on the behavior of the hardware and software components. Requires a simulation environment that can understand the semantics of both the software and the hardware components

Automated Hardware/Software Co-Synthesis n n Allow the designer to explore more of the design Automated Hardware/Software Co-Synthesis n n Allow the designer to explore more of the design space by dynamically reconfiguring the hardware and software. Another challenge for hardware/software co-synthesis is that hardware and software often described using different languages and formalisms.

Automated Hardware/Software Co-Synthesis n n n n May include hardware/software partitioning. Some of the Automated Hardware/Software Co-Synthesis n n n n May include hardware/software partitioning. Some of the considerations are: Performance requirements Implementation cost Modifiability Nature of computation Concurrency Communication

Several Examples of Hardware/Software Co-Design n n Embedded microprocessor systems Heterogeneous multiprocessing systems Application-specific Several Examples of Hardware/Software Co-Design n n Embedded microprocessor systems Heterogeneous multiprocessing systems Application-specific instruction set processors Special-purpose functional units Application-specific co-processor

Using HW/SW Codesign Alex Papadimoulis Using HW/SW Codesign Alex Papadimoulis

OOP & HW/SW Codesign n n Develop entire system in an object oriented programming OOP & HW/SW Codesign n n Develop entire system in an object oriented programming language Treat hardware as an object Allows for a unified design environment HW functions can be simulated in SW Object and implemented concurently

Problems with OOP n Synchronizing sequential code n n n Interleaved SW and HW Problems with OOP n Synchronizing sequential code n n n Interleaved SW and HW functions HW needs to know exactly when a data object is ready to be worked on Same holds true for SW

C++ Class Library – Cylib n n Handle this synchronization problem Clock function and C++ Class Library – Cylib n n Handle this synchronization problem Clock function and Done flag: n obj. Hardware. Modify( obj. Data, bln. Done); while (!(bln. Done)) { obj. Hardware. clock(); } Software. Function( obj. Data );

C++ Class Library – Cylib 2 n n Approach is similar to interrupts Complexity C++ Class Library – Cylib 2 n n Approach is similar to interrupts Complexity is greatly reduced Interface allows HW/SW objects to work hierarchical and in parallel Modification of HW design requires changing only the class library

Another Approach: Complier Generation n OOP approach won’t work for all cases Example: MPU Another Approach: Complier Generation n OOP approach won’t work for all cases Example: MPU architecture changes Traditional MPU replacement, 2 options: n n Backwards compatible hardware. Simply increase speed of functions, no new functionality. Rewrite compiler, very costly.

Complier Generation n n Theory: third option, generate compiler Radical architecture changes, compilers wouldn’t Complier Generation n n Theory: third option, generate compiler Radical architecture changes, compilers wouldn’t need time to catch up Ideal for user defined processors Extract HW architecture information then generate optimized executable code from high-level language

Complier Generation n Retargetable compilers exist n n n Require significant human skill Simply Complier Generation n Retargetable compilers exist n n n Require significant human skill Simply are superset of all CPU instructions Compiler Generator would n n Overcome retargetable compiler limitations Maintain quality (speed, size, compilation time) of conventional compiler

How it works 1 n n Optimize front-end code Architecture independent step Performed by How it works 1 n n Optimize front-end code Architecture independent step Performed by conventional compilers Passes a optimized grammar tree structure to the next step

How it works 2 n Get parameterized architecture info n n Modify tree branches How it works 2 n Get parameterized architecture info n n Modify tree branches n n Number of general registers, memory word size, instruction behavior, etc Using existing language (“twig”) Translate into pattern functions Allocate registers Generate Executable Code

Compiler Gen. Conclusion n Requires a lot of work n n n Pipelined compilation Compiler Gen. Conclusion n Requires a lot of work n n n Pipelined compilation techniques Automated architecture information extraction (perhaps HDL, etc) Experiments provide that concept could be used in HW/SW Codesign in the future