1 / 106

Architectural and System Synthesis

Architectural and System Synthesis. Camposano, J. Hofstede, Knapp, MacMillen Lin. SOURCES- DeMicheli Mark Manwaring Kia Bazargan Giovanni De Micheli Gupta Youn-Long Lin. Outline. Motivation. Compiling language models into abstract models .

ron
Download Presentation

Architectural and System Synthesis

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Architectural and System Synthesis • Camposano, • J. Hofstede, • Knapp, • MacMillenLin SOURCES- DeMicheli Mark Manwaring Kia Bazargan Giovanni De Micheli Gupta Youn-Long Lin

  2. Outline • Motivation. • Compiling language models into abstract models. • Behavioral-level optimization and program-level transformations. • Architectural synthesis: an overview.

  3. Architectural Synthesis

  4. Architectural Synthesis Problem • Specification • A sequencing graph • A set of functional resources • characterized by area and execution delay • Constraints • Tasks • Place operations in time and space • Determine detailed interconnection and control • This is what we need to do in behavioral synthesis! :) • Constraints include: area, cycle time, latency, and throughput. • Area: number of modules/resources available or size of your silicon die. • Cycle time: how fast your clock runs • Latency: number of cycles for input data to result in a solution or result. • Throughput: Amount of data that can be processed in a given amount of time (usually involves pipelining)

  5. Behavioral Optimization

  6. Resource Binding • May have a pool of resources larger than required for problem • Map a constrained set of resources to given operations • Dedicated resources: each operation is bound to a single resource. • Resource pool: may include various kinds of multipliers (booth, array, etc) adders (tree, carry-lookahead, etc.) multipurpose units (ALUs, multiplier/divider, etc.) • Mapping a given set of resources to a set of known operations is one type of problem to solve. • Dedicated resource allocation is a one-to-one mapping.

  7. Overview of Hardware Synthesis reduce the amount of hardware, optimize the design in general. May be done with the consideration of additional constraints. assign operations to physical resources under given constraints assign times to operations under given constraints

  8. Architectural versus Logic Synthesis • Transform behavioral into structural view. • Architectural-level synthesis: • Architectural abstraction level. • Determine macroscopicstructure. • Example of synthesis: major building blocks. • Logic-level synthesis: • Logic abstraction level. • Determine microscopicstructure. • Example of synthesis: logic gate interconnection.

  9. Synthesis and optimization

  10. Example of HDL description of architecture diffeq { read (x, y, u, dx, a); repeat { xl = x + dx; ul = u - (3 * x * u * dx) - (3 * y * dx); yl = y + u * dx; c = x < a; x = xl; u = ul; y = yl; } until ( c ) ; write (y); }

  11. Example of structures to implement this architecture Processes control and data

  12. Principle of scheduling and allocation

  13. Scheduling and Allocation a b c d e f g h 1 2 3 4

  14. a b c d e=a+b; g=c+d; f=e+b; h=f*g; +1 +2 e g +3 f *1 h CDFG( control data flow graph ) Internal representations • Internal representation is design back-bone of synthesis • Representations • Parse tree • Control-flow graph (CFG) • Data-flow graph (DFG, SFG) • Control/data-flow graph (CDFG)

  15. Example of trade-off in architectural design

  16. Architectural-level synthesis motivation • Raise input abstraction level. • Reduce specification of details. • Extend designer base. • Self-documenting design specifications. • Ease modifications and extensions. • Reduce design time. • Explore and optimize macroscopic structure: • Series/parallel execution of operations.

  17. Design Space Exploration We consider here totally different architectures Delay Arch I Arch II Arch III Area

  18. Stages of architectural-level synthesis • TranslateHDL models into sequencing graphs. • Behavioral-level optimization: • Optimize abstract models independently from the implementation parameters. • Architectural synthesis and optimization: • Create macroscopic structure: • data-path and control-unit. • Consider area and delay information of the implementation. (on the global level)

  19. Hardware and software compilation. software compilation. hardware compilation.

  20. High Level Synthesis Compilation Flow

  21. Compilation and behavioral optimization • Software compilation: • Compile program into intermediate form. • Optimize intermediate form. • Generate target code for an architecture. • Hardware compilation: • Compile HDL model into sequencing graph. • Optimize sequencing graph. • Generate gate-level interconnection for a cell library.

  22. Compilation • Front-end: • Lexical and syntax analysis. • Parse-tree generation. • Macro-expansion. • Expansion of meta-variables. • Semantic analysis: • Data-flow and control-flow analysis. • Type checking. • Resolve arithmetic and relational operators.

  23. Parse tree examplea = p +q r

  24. Behavioral-level optimization • Semantic-preserving transformations aiming at simplifying the model. • Applied to parse-treesor during their generation. • Taxonomy: • Data-flowbased transformations. • Control-flowbased transformations.

  25. Data-Flow Based Transformations (review) • Tree-height reduction. • Constant and variable propagation. • Common sub-expression elimination. • Dead-code elimination. • Operator-strength reduction. • Code motion. These are transformations done during compilation. There are similar transformations done during optimization to be discussed We will illustrate each

  26. Tree-height reduction • Applied to arithmetic expressions. • Goal: • Split into two-operand expressions to exploit hardware parallelism at best. • Techniques: • Balance the expression tree. • Exploit commutativity, associativity and distributivity.

  27. Example of tree-height reductionusing commutativity and associativity x = ( a + (b *c ) ) + d x = (a +d) + (b *c)

  28. Example of tree-height reductionusing distributivity x = a * (b c d +e) x = (a b) (c d) + (a e);

  29. Examples of propagation • First Transformation type: Constant propagation: • a = 0, b = a +1, c = 2 * b, • a = 0, b = 1, c = 2, • Second Transformation type: Variable propagation: • a = x, b = a +1, c = 2 * a, • a = x, b = x +1, c = 2 * x,

  30. Sub-expression elimination • Logic expressions: • Performed by logic optimization. • Kernel-based methods. • We discussed with factorization • Arithmetic expressions: • Search isomorphic patterns in the parse trees. • Example: • a = x +y, b = a +1, c = x +y, • a = x +y, b = a +1, c = a.

  31. Examples of other transformations • Dead-code elimination: • a = x; b = x +1; c = 2 * x; • a = x; can be removed if not referenced. • Operator-strength reduction: • a = x 2; b = 3 * x; • a = x * x; t = x << 1; b = x + t; • Code motion: • for (i = 1; i  a * b) { } • t = a * b; for (i = 1; i t) { } • Multiplication only once.

  32. Control- flow based transformations • Model expansion. • Conditional expansion. • Loop expansion. • Block-level transformations. • (will be discussed in more detail separately, presented on Friday) Next slides

  33. Model expansion • Expand subroutine and flatten hierarchy as the result. • Useful to expand scope of other optimization techniques. • Problematic when routine is called more than once. • Example of model expansion: • x = a +b; y = a * b; z = foo(x; y); • foo(p; q) {t = q - p; return(t); } • By expanding foo: • x = a +b; y = a * b; z = y - x foo does subtraction

  34. Conditional expansion • Transform conditional into parallel execution with test at the end. • Useful when test depends on late signals. • May preclude hardware sharing. • Always useful for logic expressions. • Example: • y = ab;if (a) {x = b + d; } else {x = bd;} • can be expanded to: x = a(b +d) +a’bd • and simplified as: y = ab; x = y +d(a +b) Moves conditionals from control unit to data path

  35. Loop expansion • Applicable to loops with data-independent exit conditions. • Useful to expand scope of other optimization techniques. • Problematic when loop has many iterations. • Example of loop expansion: • x = 0; for (i = 1; i  3; i ++) {x = x +1; } • Expanded to: x = 0; x = x +1; x = x +2; x = x +3 Can use various variable semantics

  36. What is architectural synthesis and optimization • Synthesize macroscopic structure in terms of building-blocks. • Explore area/performance trade-offs: • maximum performanceimplementations subject to area constraints. • minimum areaimplementations subject to performance constraints. • Determine an optimal implementation. • Create logic model for data-path and control.

  37. Design space and objectives in architectural synthesis • Design space: • Set of all feasible implementations. • Implementation parameters: • Area. • Performance: • Cycle-time. • Latency. • Throughput (for pipelined implementations). • Power consumption

  38. Three dimensional Design evaluation space

  39. Hardware modeling • Circuit behavior: • Sequencing graphs. • Building blocks: • Resources. • Constraints: • Timing and resource usage. Our methods and data structures have to model them for architectural design

  40. What are Resources? • Functional resources: • Perform operations on data. • Example: arithmetic and logic blocks. • Memory resources: • Store data. • Example: memory and registers. • Interface resources: • Example: busses and ports.

  41. Functional resources • Standard resources: • Existing macro-cells. • Well characterized (area/delay). • Example: adders, multipliers, ... • Application-specific resources: • Circuits for specific tasks. • Yet to be synthesized. • Example: instruction decoder.

  42. Resources and circuit families • Resource-dominated circuits. • Area and performance depend on few, well-characterized blocks. • Example: DSP circuits. • Non resource-dominated circuits. • Area and performance are strongly influenced by sparse logic, control and wiring. • Example: some ASIC circuits.

  43. Implementation constraints • Timing constraints: • Cycle-time. • Latency of a set of operations. • Time spacing between operation pairs. • Resource constraints: • Resource usage (or allocation). • Partial binding.

  44. Synthesis in the temporal domain • Scheduling: • Associate a start-time with each operation. • Determine latency and parallelism of the implementation. • Scheduled sequencing graph: • Sequencing graph with start-timeannotation. Result of scheduling

  45. Example of Synthesis in the temporal domain ASAP Here we use sequencing graph

  46. Synthesis in the spatial domain • Binding: • Associate a resource with each operation with the same type. • Determine area of the implementation. • Sharing: • Bind a resource to more than one operation. • Operations must not execute concurrently. • Bound sequencing graph: • Sequencing graph with resource annotation.

  47. Example of Synthesis in the spatial domain • Second multiplier • First multiplier • Third multiplier • Fourth multiplier • First ALU • Second ALU • Solution • Four Multipliers • Two ALUs • Four Cycles

  48. Binding specification • Mapping from the vertex set to the set of resource instances, for each given type. • Partial binding: • Partial mapping, • given as design constraint. • Compatible binding: • Binding which is satisfying the constraints of the partial binding. cont

  49. Example of Binding specification • Binding to the same multiplier

More Related