Introduction to the Center for Systems and Software Engineering XTEAM: Automated Synthesis of Domain-Specific Code Generators George Edwards [email protected] Brief Introduction to CSSE • Established in 1993 as CSE – Merged in 2006 with SAE to form CSSE • Focus on research and teaching – MSCS with emphasis in SE – Graduate Certificate in SAE – Two Certificate and Advanced Degree programs • Objective is to solve scientific problems with industrial relevance CSSE Affiliates • 22 industrial affiliates – 8 from aerospace industry – 12 from other industries – 2 international • 12 government affiliates – 6 government agencies • incl. US Army TACOM and Research Labs – 6 FFRDCs and consortia • 7 academic affiliates – 5 universities – 2 research centers • 3 visiting associates Research Focus Areas • • • • Architecture Economics Process Testing & analysis Software Architecture Research • • • • • • • • Modeling Analysis Implementation Deployment Dynamic adaptation Architectural styles Software connectors Architectural recovery XTEAM Project Overview • Processes, notations, tools, and designs that enable automated synthesis of end-to-end domain-specific toolsets for software architecture modeling, analysis, and code generation • Example application areas: – Systems-of-systems and ultra-large-scale systems – Safety- and mission-critical systems – Cloud and grid systems • Domain-Specific Languages (DSLs) Customized for a particular family of problems (the domain) • Concise and intuitive – No missing or extra features – Capture patterns – Enforce constraints – Use native symbols and terms • Can be modified, evolved, and composed Model-Driven Engineering (MDE) • MDE leverages DSLs for architecture modeling – Metamodels define DSL syntax (types, properties, views, and constraints) – Model interpreters define DSL semantics (analysis, code generation, etc.) • MDE platforms provide (some) tool support – Metamodel editor with built-in metamodeling language – Metamodel interpreter that configures a metaprogrammable model editor Off-theshelf Metamodel Editor Metaprogrammable Model Editor Auto generated Metamodeling Domain-Specific Language Language Built by engineer Metamodel Interpreter Metamodel Domain-Specific Domain-Specific Domain-Specific Model Model Model 8 Model Execution Environment (Semantic Domain) Model Interpreter Executable Executable Executable Model Model Model Problems with MDE • Building and maintaining code generators for DSLs is inherently difficult – High design complexity – Disproportionate maintenance and evolution costs – Hard to verify correctness – Redundant development effort – Opaque semantics embedded in source code “The difficulty of building and “There is a fundamental problem maintaining DSM solution “Checkinga mathematical in keeping the model interpreters “The state-of-the-art model stems essentially from theof properties like correctness or “Writing translators by hand... up to date withwriting metamodel interpreter needs to be complexity of theof mapping completeness transformations in addition to being inefficient, has changes ... Current practice advanced to enhance the between concept instances based on common programming yetthe another serious drawback: requires each model interpreter toofthe reusability and maintainability expressed in the DSML and the languages is very difficult...” semantic mapping between be modified manually after each the this software...” code that hasand to the be generated.” input output is vaguely metamodel schema change. This I. Malavolta, H. Muccini, P. Pelliccione, specified...[Building modelandof be aTamburri. very time-consuming G. Karsai. Structured Specification A.can L.and Santos D. et al. Automating Providing the Architectural interpreters] is the most time Model Interpreters. Engineering of error prone task for Interoperability complex model Construction Languages ofand Domain-Specific Tools consuming and error prone Computer-Based 1999. interpreters of considerable size.”phase Modeling through Languages Model Transformation forSystems, Object-Oriented of theJournal MIC approach...” Frameworks. Technologies. IEEE ofTransactions Software and on Systems, Jing Software Zhang. 2010. Engineering, Metamodel-Driven 2009. Model G. Karsai, A. Agrawal, F. Shi, J.on Sprinkle. Interpreter Evolution. Conference the UseProgramming of Graph Transformation ObjectOn Oriented Systems in the Formal Specification2005. of Model Languages and Applications, Interpreters. Journal of Universal Computer Science, 2003. FCS: A Real World Example • > $100 billion US Army program • DSL with hundreds of types – Modified on a daily basis • Automated generation of: – – – – Discrete event simulations Middleware configuration files Fault trees Spreadsheets for documentation Tool building and maintenance required approximately five full-time MDE experts XTEAM Solution Approach Synthesize domain-specific code generators using the same mechanisms that have proven successful for synthesizing domain-specific model editors. Model Editor Framework Metamodel Editor Presentation Semantics Metamodel Metamodel Interpreter A Presentation Rules Presentation Logic Types and Views Application Model Presentation Properties (Abstract Representation) Platform Properties Metamodel Interpreter B Platform Semantics Target Display Model Interpreter Framework Code Generation Logic Code Generation Rules Visualized Model Target Platform Executable Model Off-the-Shelf Component XTEAM Toolset XTEAM Component Connector Languages and Platforms Repository GME Model Editor Metainterpreter XTEAM Metalanguage MS COM GME XDEVS MIF Extensions XDEVS XDEVS Simulations Discrete Event (C++) Simulation Engine XDEVS MIF C++ XTEAM DSLs XDEVS MS COM XTEAM Metamodels (XML/HTTP) GME XTEAM Model Models Fedora Linux (XML/HTTP) Editor MS COM SVN Metainterpreter Prism-MW Metainterpreter Windows/C++/Visual Studio 12 Prism-MW MIF Extensions Prism-MW MIF Prism-MW Applications (Java) Prism-MW Lightweight Architectural Middleware JVM XTEAM Simulations • Providing design rationale • Weighing architectural trade-offs • Discovering emergent behavior of component assemblies • Validating component implementations 13 Providing Design Rationale – What architectural style to use – How to allocate functionality among subsystems – What types of connectors to use • XTEAM allows architects to rationalize such decisions with experimental evidence – Model confidence level: Low Peer-to-peer Architecture Potential Workload Request File Response Time 2500 Response Time (ms) • Architects rely on intuition and experience to make important decisions early in the design phase Client-Server Architecture 2000 1500 1000 500 0 1 6 11 16 21 26 31 36 41 46 51 56 61 66 71 Invocation 76 81 86 91 96 Weighing Architectural Trade-offs • Nearly all architectural decisions come down to trade-offs between multiple desirable properties – Emphasis on one system property may yield diminishing returns • XTEAM allows architects to evaluate design alternatives in terms of their impact on multiple non-functional properties – Model confidence level: Medium Decreases response time Replication of components Request File Response T ime Response Time (ms) 2500 2000 1500 1000 500 0 1 6 11 16 21 26 31 36 41 46 51 56 Invocation 61 66 71 76 81 86 91 96 Consumes more battery power Host A (iPAQ) Battery Power Remaining Energy (mJ) 24000 23500 23000 22500 22000 0 58944 104612 175249 239514 287914 352870 415963 480308 Time (ms) S… 529223 Evaluating Component Assemblies • Contemporary large-scale distributed systems contain numerous off-theshelf components – Detailed information about the behaviors and properties of individual components may be known – Component assemblies may exhibit unforeseen behavior due to subtle interactions between constituent components • XTEAM allows an architect to determine the emergent properties of a composed system – Model confidence level: High Off-the-shelf components Highly accurate parameterization Determination of emergent properties Incremental System Validation • Individual component implementations may become available in a piecemeal fashion XTEAM allows architects to • 1. 2. – Immediately incorporate component implementations into a simulated system, increasing the accuracy of analysis results Rapidly test individual components in the context of a wide variety of operational scenarios Model confidence level: High Component implementation available Invoke implementation from behavior model Integrated simulation and test environment For More Information • CSSE Website: http://csse.usc.edu/csse/ • XTEAM Website: http://www-scf.usc.edu/~gedwards/xteam.html
© Copyright 2026 Paperzz