1 / 30

Starfish: A Table-Centric Tool for Design Derivation

Starfish: A Table-Centric Tool for Design Derivation . Alex Tsow The MITRE Corporation.

agnes
Download Presentation

Starfish: A Table-Centric Tool for Design Derivation

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. Starfish: A Table-Centric Tool for Design Derivation Alex Tsow The MITRE Corporation Affiliation with The MITRE Corporation is provided for identification purposes only, and is not intended to convey or imply MITRE's concurrence with, or support for, the positions, opinions or viewpoints expressed by the author.

  2. Thanks to the NASA Langley Research Center • This work was supported by a 3 year fellowship from the Graduate Student Researchers Program (GSRP). • Sponsorship originated from NASA Langley Formal Methods Group Ricky Butler Paul S. Miner

  3. Design Derivation • Formally generates systems • Transformational algebra • Contrast with post-design formal verification • Synchronous stream networks • Manual interaction • How best to achieve interaction? • How best to deliver a deep transformation space?

  4. Two Common System Views

  5. Behavior Tables Selector keys Signals Branches Updates Decision Table Action Table

  6. Starfish • Tool for behavior table manipulation • Implements transformation algebra • b.t. display and derivation playback • Explicit type system • Data Refinement • Interactive Serialization Tables • Environment for high-level synthesis • Retiming

  7. Related Work • Transformation systems • Eisenbiegler & Kumar, Formally Embedding Existing High Level Synthesis Algorithms • Teica, Radhakrishnan & Vemuri, An Approach to High Level Synthesis & System Validation Using Formally Verified Transformations • Matthews & Launchbury, ElementaryMicroarchitecture Algebra • Table-Oriented Engineering • Heninger, Kallander, Parnas & Shore, Software Requirements for the A-7 Aircraft • Heitmeyer, Labaw, et.al. SCR* • Leveson et.al., RSML • Algebraic Specification • Goguen, Thatcher, Wagner (ADJ), Initial Algebra Approach to the Specification, Correctness, and Implementation of Abstract Data Types • Gurevich, Evolving Algebras

  8. Behavior Table Semantics StackCalc(inst,a)=res where res = (top s) s = {0} ! (sel (inst-cat instr) (push s a) (pop s) (push (pop (pop s)) (alu (inst->op instr) (top s) (top (pop s))))) Inputs instr = (push, push, add …) a = (5, 22, 2007, …) Internal Signals: res = ( 0, 5, 22, 27 …) s = ({0}, {0,5}, {0,5,22}, {0,27}, …)

  9. Table Algebra • Add/Remove signal • Apply a term-level algebraic identity • Instantiate a “don’t care” subterm • Substitute combinational action for variable • Tuple/Untuple signals • Add/Remove decision key • Instantiate decision branches • Substitute branch value for decision key term • Split a table into multiple tables

  10. System Factorization

  11. System Factorization

  12. Creating Factorization Opportunities • Retiming • Serialization • Data Refinement

  13. Retiming update instr s a {0} top res update instr s a {0} top res 0

  14. Add Tail Signal Expand ‘s’ Combinational identities Simplify ‘res’ and ‘tl’ Eliminate ‘s’ Retiming Retiming ‘res’ and ‘tl’’

  15. High-Level Synthesis pop pop pop top push s alu top instr Data Flow Graph for (push (pop (pop s)) (alu-op instr (top s) (top (pop s))))

  16. High-Level Synthesis pop pop top push s alu top instr

  17. High-Level Synthesis pop pop top push s alu top instr

  18. High-Level Synthesis pop pop top push s alu top instr

  19. High-Level Synthesis pop s s pop top push s s s s s y x alu top x x x instr

  20. Serialization Tables Scheduling Table Evaluation Table Term Eval Actions Evaluation Requirements

  21. Insert schedule into behavior table Propose final step & Confirm requirements Serialization in Starfish

  22. Types in Starfish • Multi-sorted structures with identities • Enforces syntactic correctness • Identity database for term manipulation • Declarative structures • Unbounded types; groups • Enumerated types; booleans, states • Parameterized types; stacks over data • Inter-type functions and identities • Special types and expressions • Polymorphic tuples & selectors, bit vectors, integers

  23. Types in Starfish • Type inferencing is necessary • What’s the type of empty-stack? • Type annotations • Facilities for type translation • One-to-one • One-to-many • Choice of representation contingent on current representation: A,R) R • Stateful refinement, reference-state pattern

  24. Stack to Array Transformation Apply to instances of ‘top’ Apply to ‘s’

  25. Apply to signals ‘s’ and ‘tl’ Apply to instances of ‘top’ Stack to Linked List

  26. Full StackCalc Decomposition Controller Memory ALU

  27. Garbage Collector Derivation

  28. Garbage Collector Derivation Factor out abstract memories Encapsulate memory with function names Apply switch refinement Move sw into DT

  29. SECD Derivation (define secd (letrec ([exec (lambda (s e c d) (case (car c) ('RTN (exec (cons (car s) (car d)) ...)) ('DUM (exec s (cons nil e) (cdr c) d)) ('AP (exec '() (cons (car (cdr s)) (cdr (car s))) (car (car s)) (cons (cdr (cdr s)) (cons e (cons (cdr c) d))))) … ('STOP (exec s e c d))))]) exec ))

  30. Conclusion / Future Work • Starfish expands factorization space • Behavior table viewer and transformer • Explicit type system and data refinement • High Level Synthesis w/ Serialization tables • Retiming • Interface/Transaction Specification • Integration with other tools • DDD / Theorem provers / CASL • Develop backends to synchronous targets • FPGAs • Multicore systems / real-time software

More Related