Generative software development is a system-family approach that focuses on automating the creation of system-family members. A given system can be automatically generated from a specification written in one or more domain-specific languages. Domain-specific languages are used to specify systems at a high level of abstraction in a particular problem domain, while mappings and solution components implement the specification in a lower-level solution space. This allows automatic generation of systems from concise, domain-focused specifications.
Presentation done at the historic 20 yeras of C++ conference in Las Vegas 2005. This is also the first time I ever spoke on the topic of combing generative programming and C++ template metaprogramming
The document discusses practical generative programming. It defines generative programming as automatically manufacturing customized products from reusable components using configuration knowledge. It describes the key elements and steps of generative programming. It discusses strategies for implementing generative programming in C++, including using templates and traits classes to configure generic components. It provides an example of how to capture configuration metadata in XML to define attributes like port ranges and generate C++ code.
Towards Automated Design Space Exploration and Code Generation using Type Tra...waqarnabi
Slides for talk at First International Workshop on Heterogeneous High-performance Reconfigurable Computing (H2RC'15), Austin, Texas, Nov 15 2015. Held in conjunction with SC15.
The document discusses assertion based verification and interfaces in SystemVerilog. It describes immediate assertions which execute in zero simulation time and can be placed within always blocks. Concurrent assertions check properties over time and are evaluated at clock edges. The document also introduces interfaces in SystemVerilog which allow defining communication ports between modules in a single place, reducing repetitive port definitions. Interfaces can include protocol checking and signals can be shared between interface instances.
Finding Bugs Faster with Assertion Based Verification (ABV)DVClub
1) Assertion-based verification introduces assertions into a design to improve observability and controllability during simulation and formal analysis.
2) Assertions define expected behavior and can detect errors by monitoring signals within a design.
3) An assertion-based verification methodology leverages assertions throughout the verification flow from module to system level using various tools like simulation, formal analysis, and acceleration for improved productivity, quality, and reduced verification time.
Aldec is a leading EDA company founded in 1984 that provides RTL simulation, verification, and emulation solutions. It has over 200 employees and 30,000 licenses worldwide. Aldec's key products include Active-HDL for simulation, Riviera-PRO for verification, ALINTTM for linting, and HES for emulation. Aldec focuses on continuous innovation to provide better performance, more features, and lower prices than competitors.
The document discusses several advanced verification features in SystemVerilog including the Direct Programming Interface (DPI), regions, and program/clocking blocks. The DPI allows Verilog code to directly call C functions without the complexity of Verilog PLI. Regions define the execution order of events and include active, non-blocking assignment, observed, and reactive regions. Clocking blocks make timing and synchronization between blocks explicit, while program blocks provide entry points and scopes for testbenches.
មេរៀនៈ Data Structure and Algorithm in C/C++Ngeam Soly
This document provides an introduction to a lecture on data structures and algorithms. It discusses the lecturer's contact information and expectations for reading ahead of lectures. It then covers topics that will be discussed in the course, including programs and programming, introduction to programming, crafting programs effectively, what makes a good program, and why data structures and algorithms are important subjects. The document provides an overview of what will be covered in the course.
Presentation done at the historic 20 yeras of C++ conference in Las Vegas 2005. This is also the first time I ever spoke on the topic of combing generative programming and C++ template metaprogramming
The document discusses practical generative programming. It defines generative programming as automatically manufacturing customized products from reusable components using configuration knowledge. It describes the key elements and steps of generative programming. It discusses strategies for implementing generative programming in C++, including using templates and traits classes to configure generic components. It provides an example of how to capture configuration metadata in XML to define attributes like port ranges and generate C++ code.
Towards Automated Design Space Exploration and Code Generation using Type Tra...waqarnabi
Slides for talk at First International Workshop on Heterogeneous High-performance Reconfigurable Computing (H2RC'15), Austin, Texas, Nov 15 2015. Held in conjunction with SC15.
The document discusses assertion based verification and interfaces in SystemVerilog. It describes immediate assertions which execute in zero simulation time and can be placed within always blocks. Concurrent assertions check properties over time and are evaluated at clock edges. The document also introduces interfaces in SystemVerilog which allow defining communication ports between modules in a single place, reducing repetitive port definitions. Interfaces can include protocol checking and signals can be shared between interface instances.
Finding Bugs Faster with Assertion Based Verification (ABV)DVClub
1) Assertion-based verification introduces assertions into a design to improve observability and controllability during simulation and formal analysis.
2) Assertions define expected behavior and can detect errors by monitoring signals within a design.
3) An assertion-based verification methodology leverages assertions throughout the verification flow from module to system level using various tools like simulation, formal analysis, and acceleration for improved productivity, quality, and reduced verification time.
Aldec is a leading EDA company founded in 1984 that provides RTL simulation, verification, and emulation solutions. It has over 200 employees and 30,000 licenses worldwide. Aldec's key products include Active-HDL for simulation, Riviera-PRO for verification, ALINTTM for linting, and HES for emulation. Aldec focuses on continuous innovation to provide better performance, more features, and lower prices than competitors.
The document discusses several advanced verification features in SystemVerilog including the Direct Programming Interface (DPI), regions, and program/clocking blocks. The DPI allows Verilog code to directly call C functions without the complexity of Verilog PLI. Regions define the execution order of events and include active, non-blocking assignment, observed, and reactive regions. Clocking blocks make timing and synchronization between blocks explicit, while program blocks provide entry points and scopes for testbenches.
មេរៀនៈ Data Structure and Algorithm in C/C++Ngeam Soly
This document provides an introduction to a lecture on data structures and algorithms. It discusses the lecturer's contact information and expectations for reading ahead of lectures. It then covers topics that will be discussed in the course, including programs and programming, introduction to programming, crafting programs effectively, what makes a good program, and why data structures and algorithms are important subjects. The document provides an overview of what will be covered in the course.
This document discusses hardware description languages used in electronics design. It describes how HDLs like VHDL and Verilog are used to program digital and mixed-signal circuits. Simulation allows validation of the design against specifications. The document also discusses formal verification using property specification languages and different modeling styles for Verilog like gate-level, dataflow, and behavioral modeling.
HDL stands for hardware description language. It is a textual language used to formally describe and design electronic circuits and digital logic. HDL allows for automated analysis, simulation, and testing of electronic circuits before they are physically implemented. Common HDLs include VHDL and Verilog. HDL is used to write executable specifications for hardware and model circuits before physical creation, enabling simulation and synthesis into programmable logic devices like FPGAs.
Efficient and Advanced Omniscient Debugging for xDSMLs (SLE 2015)Benoit Combemale
Talk given at the 8th ACM SIGPLAN Int'l Conf. on Software Language Engineering (SLE 2015), Pittsburgh, PA, USA on October 27, 2015. Preprint available at https://hal.inria.fr/hal-01182517
Verilog is a hardware description language that can be used to describe digital systems like microprocessors, switches, and memory. It allows designs to be created using either a bottom-up or top-down methodology. Bottom-up designs are built up from individual gates, while top-down designs start at a higher level and are easier to change. Verilog supports designing at different levels of abstraction like behavioral, register-transfer, and gate levels.
The document discusses hardware description languages (HDLs) which are used to describe digital systems in a textual format similar to programming languages. It notes that HDLs represent parallel operations while programming languages focus on serial operations. Two standard HDLs are VHDL and Verilog. The document then describes the typical design flow when using HDLs, including writing HDL code, simulation, synthesis to map to hardware primitives, fitting to target technologies, and timing analysis.
D11: a high-performance, protocol-optional, transport-optional, window system...Mark Kilgard
Consider the dual pressures toward a more tightly integrated workstation window system: 1) the need to efficiently handle high bandwidth services such as video, audio, and three-dimensional graphics; and 2) the desire to achieve the under-realized potential for local window system performance in X11.
This paper proposes a new window system architecture called D11 that seeks higher performance while preserving compatibility with the industry-standard X11 window system. D11 reinvents the X11 client/server architecture using a new operating system facility similar in concept to the Unix kernel's traditional implementation but designed for user-level execution. This new architecture allows local D11 programs to execute within the D11 window system kernel without compromising the window sytem's integrity. This scheme minimizes context switching, eliminates protocol packing and unpacking, and greatly reduces data copying. D11 programs fall back to the X11 protocol when running remote or connecting to an X11 server. A special D11 program acts as an X11 protocol translator to allow X11 programs to utilize a D11 window system.
[The described system was never implemented.]
This document discusses subprograms and parameter passing in programming languages. It covers fundamental concepts of subprograms like definitions, calls, headers, and parameters. It then describes different parameter passing methods like pass-by-value, pass-by-reference, and pass-by-name. It also discusses how major languages like C, C++, Java, Ada, C#, and PHP implement parameter passing and type checking.
This document provides an overview of the ECE 551 Digital Design and Synthesis course for Fall 2009 at UW-Madison. It introduces the instructor, Eric Hoffman, and TA Vinod Nalamalapu. It outlines course goals, materials, tools, evaluation criteria and schedule. Key topics covered include Verilog, simulation, synthesis, FPGAs, standard cells and digital design flows. Students are expected to have prior knowledge of digital logic concepts from ECE 352.
This document discusses subprograms (also called subroutines) in programming languages. It covers:
- The basic definitions and characteristics of subprograms, including headers, parameters, and local variables.
- Different parameter passing methods like pass-by-value, pass-by-reference, and their implementation in common languages.
- Additional features of subprograms including overloading, generics, and functions passing subprograms as parameters.
Verilog Ams Used In Top Down Methodology For Wireless Integrated CircuitsRégis SANTONJA
The document discusses using the VerilogAMS language and top-down methodology for wireless integrated circuit designs. Specifically, it discusses:
1) Using the top-down methodology to allow for general functionality verification early in the design process by analyzing the ASIC from top to bottom before individual block implementation.
2) Describing the steps of behavioral modeling of blocks using VerilogA, replacing blocks with transistor-level designs, and simulating the entire design with mixed behavioral and transistor-level blocks.
3) Noting that the top-down methodology can be applied whether the design has a large analog/small digital portion or large digital/small analog portion.
OpenGL Based Testing Tool Architecture for Exascale ComputingCSCJournals
1) The document proposes an OpenGL based testing tool architecture for exascale computing to improve performance and accuracy of OpenGL programs.
2) It identifies common errors that occur when programming shaders in OpenGL Shading Language (GLSL) such as errors in file reading, compilation, linking, and rendering.
3) The proposed testing architecture divides the GLSL programming process into four stages - file reading, compilation, pre-linking/linking, and rendering - and validates each stage to detect errors and enforce error-free code.
Python programming concepts for the Internet of things applications development. This PPT contains details about classes, list , tuples, dictionaries, packages like HTTPLib,SMTPLib, etc
This document discusses key concepts related to variables in programming languages including names, bindings, scopes, and lifetimes. It covers different types of variables such as static, stack dynamic, and heap dynamic variables. It also compares static and dynamic scoping models and how they determine variable visibility. The referencing environment is defined as the collection of all visible variables for a given statement.
This document discusses subprograms and parameters in programming languages. It covers:
1. Characteristics of subprograms like having a single entry point and control returning to the caller.
2. Definitions related to subprograms like subprogram definitions, calls, headers, and parameters.
3. Issues with parameter passing like positional vs keyword parameters, default values, and different passing methods.
4. Design considerations for subprograms like parameter types, local variables, nested and overloaded subprograms, and independent compilation.
This document describes a primitive processing and advanced shading architecture for embedded systems. It features a vertex cache and programmable primitive engine that can process fixed and variable size primitives with reduced memory bandwidth requirements. The architecture includes a configurable per-fragment shader that supports various shading models using dot products and lookup tables stored on-chip. This hybrid design aims to bring appealing shading to embedded applications while meeting limitations on gate size, power consumption, and memory traffic growth.
The document describes a SystemVerilog verification methodology that includes assertion-based verification, coverage-driven verification, constrained random verification, and use of scoreboards and checkers. It outlines the verification flow from design specifications through testbench development, integration and simulation, and discusses techniques like self-checking test cases, top-level and block-level environments, and maintaining bug reports.
CSEG1001 Lecture 1 Introduction to ComputersDhiviya Rose
This document outlines the course CSEG1001 Computer Programming. It covers several topics that will be taught over the course including the evolution of computers from the abacus to modern devices, generations of computers, programming languages, and basic programming concepts like algorithms, flowcharts, and pseudocode. The course roadmap shows it will cover introduction to computers, C programming basics, arrays and strings, functions and pointers, structures and unions.
Bolt C++ Standard Template Libary for HSA by Ben Sanders, AMDHSA Foundation
The document introduces Bolt, a C++ template library for heterogeneous system architecture (HSA) that aims to improve developer productivity for GPU programming. Bolt provides optimized library routines for common GPU operations using open standards like OpenCL and C++ AMP. It resembles the familiar C++ Standard Template Library. Bolt allows programming GPUs as easily as CPUs, handles workload distribution across devices, and provides a single source code base for both CPU and GPU. Examples show how Bolt can be used with C++ AMP and OpenCL, including passing user-defined functors. An exemplary video enhancement application demonstrates Bolt's use in a commercial product.
Seeking Enligtenment - A journey of purpose rather tan instructionSchalk Cronjé
The document discusses the benefits of exercise for mental health. Regular physical activity can help reduce anxiety and depression and improve mood and cognitive functioning. Exercise causes chemical changes in the brain that may help boost feelings of calmness, happiness and focus.
Generative Programming In The Large - Applied C++ meta-programmingSchalk Cronjé
Digs into the details of effective generative programming in C++. Major focus on using meta-programming techniques to create efficient, low cyclomatic complexity in artefacts.
This document discusses hardware description languages used in electronics design. It describes how HDLs like VHDL and Verilog are used to program digital and mixed-signal circuits. Simulation allows validation of the design against specifications. The document also discusses formal verification using property specification languages and different modeling styles for Verilog like gate-level, dataflow, and behavioral modeling.
HDL stands for hardware description language. It is a textual language used to formally describe and design electronic circuits and digital logic. HDL allows for automated analysis, simulation, and testing of electronic circuits before they are physically implemented. Common HDLs include VHDL and Verilog. HDL is used to write executable specifications for hardware and model circuits before physical creation, enabling simulation and synthesis into programmable logic devices like FPGAs.
Efficient and Advanced Omniscient Debugging for xDSMLs (SLE 2015)Benoit Combemale
Talk given at the 8th ACM SIGPLAN Int'l Conf. on Software Language Engineering (SLE 2015), Pittsburgh, PA, USA on October 27, 2015. Preprint available at https://hal.inria.fr/hal-01182517
Verilog is a hardware description language that can be used to describe digital systems like microprocessors, switches, and memory. It allows designs to be created using either a bottom-up or top-down methodology. Bottom-up designs are built up from individual gates, while top-down designs start at a higher level and are easier to change. Verilog supports designing at different levels of abstraction like behavioral, register-transfer, and gate levels.
The document discusses hardware description languages (HDLs) which are used to describe digital systems in a textual format similar to programming languages. It notes that HDLs represent parallel operations while programming languages focus on serial operations. Two standard HDLs are VHDL and Verilog. The document then describes the typical design flow when using HDLs, including writing HDL code, simulation, synthesis to map to hardware primitives, fitting to target technologies, and timing analysis.
D11: a high-performance, protocol-optional, transport-optional, window system...Mark Kilgard
Consider the dual pressures toward a more tightly integrated workstation window system: 1) the need to efficiently handle high bandwidth services such as video, audio, and three-dimensional graphics; and 2) the desire to achieve the under-realized potential for local window system performance in X11.
This paper proposes a new window system architecture called D11 that seeks higher performance while preserving compatibility with the industry-standard X11 window system. D11 reinvents the X11 client/server architecture using a new operating system facility similar in concept to the Unix kernel's traditional implementation but designed for user-level execution. This new architecture allows local D11 programs to execute within the D11 window system kernel without compromising the window sytem's integrity. This scheme minimizes context switching, eliminates protocol packing and unpacking, and greatly reduces data copying. D11 programs fall back to the X11 protocol when running remote or connecting to an X11 server. A special D11 program acts as an X11 protocol translator to allow X11 programs to utilize a D11 window system.
[The described system was never implemented.]
This document discusses subprograms and parameter passing in programming languages. It covers fundamental concepts of subprograms like definitions, calls, headers, and parameters. It then describes different parameter passing methods like pass-by-value, pass-by-reference, and pass-by-name. It also discusses how major languages like C, C++, Java, Ada, C#, and PHP implement parameter passing and type checking.
This document provides an overview of the ECE 551 Digital Design and Synthesis course for Fall 2009 at UW-Madison. It introduces the instructor, Eric Hoffman, and TA Vinod Nalamalapu. It outlines course goals, materials, tools, evaluation criteria and schedule. Key topics covered include Verilog, simulation, synthesis, FPGAs, standard cells and digital design flows. Students are expected to have prior knowledge of digital logic concepts from ECE 352.
This document discusses subprograms (also called subroutines) in programming languages. It covers:
- The basic definitions and characteristics of subprograms, including headers, parameters, and local variables.
- Different parameter passing methods like pass-by-value, pass-by-reference, and their implementation in common languages.
- Additional features of subprograms including overloading, generics, and functions passing subprograms as parameters.
Verilog Ams Used In Top Down Methodology For Wireless Integrated CircuitsRégis SANTONJA
The document discusses using the VerilogAMS language and top-down methodology for wireless integrated circuit designs. Specifically, it discusses:
1) Using the top-down methodology to allow for general functionality verification early in the design process by analyzing the ASIC from top to bottom before individual block implementation.
2) Describing the steps of behavioral modeling of blocks using VerilogA, replacing blocks with transistor-level designs, and simulating the entire design with mixed behavioral and transistor-level blocks.
3) Noting that the top-down methodology can be applied whether the design has a large analog/small digital portion or large digital/small analog portion.
OpenGL Based Testing Tool Architecture for Exascale ComputingCSCJournals
1) The document proposes an OpenGL based testing tool architecture for exascale computing to improve performance and accuracy of OpenGL programs.
2) It identifies common errors that occur when programming shaders in OpenGL Shading Language (GLSL) such as errors in file reading, compilation, linking, and rendering.
3) The proposed testing architecture divides the GLSL programming process into four stages - file reading, compilation, pre-linking/linking, and rendering - and validates each stage to detect errors and enforce error-free code.
Python programming concepts for the Internet of things applications development. This PPT contains details about classes, list , tuples, dictionaries, packages like HTTPLib,SMTPLib, etc
This document discusses key concepts related to variables in programming languages including names, bindings, scopes, and lifetimes. It covers different types of variables such as static, stack dynamic, and heap dynamic variables. It also compares static and dynamic scoping models and how they determine variable visibility. The referencing environment is defined as the collection of all visible variables for a given statement.
This document discusses subprograms and parameters in programming languages. It covers:
1. Characteristics of subprograms like having a single entry point and control returning to the caller.
2. Definitions related to subprograms like subprogram definitions, calls, headers, and parameters.
3. Issues with parameter passing like positional vs keyword parameters, default values, and different passing methods.
4. Design considerations for subprograms like parameter types, local variables, nested and overloaded subprograms, and independent compilation.
This document describes a primitive processing and advanced shading architecture for embedded systems. It features a vertex cache and programmable primitive engine that can process fixed and variable size primitives with reduced memory bandwidth requirements. The architecture includes a configurable per-fragment shader that supports various shading models using dot products and lookup tables stored on-chip. This hybrid design aims to bring appealing shading to embedded applications while meeting limitations on gate size, power consumption, and memory traffic growth.
The document describes a SystemVerilog verification methodology that includes assertion-based verification, coverage-driven verification, constrained random verification, and use of scoreboards and checkers. It outlines the verification flow from design specifications through testbench development, integration and simulation, and discusses techniques like self-checking test cases, top-level and block-level environments, and maintaining bug reports.
CSEG1001 Lecture 1 Introduction to ComputersDhiviya Rose
This document outlines the course CSEG1001 Computer Programming. It covers several topics that will be taught over the course including the evolution of computers from the abacus to modern devices, generations of computers, programming languages, and basic programming concepts like algorithms, flowcharts, and pseudocode. The course roadmap shows it will cover introduction to computers, C programming basics, arrays and strings, functions and pointers, structures and unions.
Bolt C++ Standard Template Libary for HSA by Ben Sanders, AMDHSA Foundation
The document introduces Bolt, a C++ template library for heterogeneous system architecture (HSA) that aims to improve developer productivity for GPU programming. Bolt provides optimized library routines for common GPU operations using open standards like OpenCL and C++ AMP. It resembles the familiar C++ Standard Template Library. Bolt allows programming GPUs as easily as CPUs, handles workload distribution across devices, and provides a single source code base for both CPU and GPU. Examples show how Bolt can be used with C++ AMP and OpenCL, including passing user-defined functors. An exemplary video enhancement application demonstrates Bolt's use in a commercial product.
Seeking Enligtenment - A journey of purpose rather tan instructionSchalk Cronjé
The document discusses the benefits of exercise for mental health. Regular physical activity can help reduce anxiety and depression and improve mood and cognitive functioning. Exercise causes chemical changes in the brain that may help boost feelings of calmness, happiness and focus.
Generative Programming In The Large - Applied C++ meta-programmingSchalk Cronjé
Digs into the details of effective generative programming in C++. Major focus on using meta-programming techniques to create efficient, low cyclomatic complexity in artefacts.
The document discusses practical meta-programming using C++ templates. It explains how template specialization and partial specialization allow recursive instantiation of templates to transform types and data at compile-time in a functional programming-like manner. Examples are provided to demonstrate summing values, checking type traits, approximating mathematical functions, and creating heterogeneous tuples through recursive templates. SFINAE (substitution failure is not an error) is also introduced as a way to selectively overload functions based on type traits.
A Generative Programming Approach to Developing Pervasive Computing SystemsDamien Cassou
This document presents a generative programming approach to developing pervasive computing systems. It describes challenges in pervasive computing like heterogeneity, lack of structure, and dynamicity. It proposes addressing these through domain-specific languages to describe devices, architectures, and generate a programming framework and simulation support. This approach aims to guide development and ensure conformance while abstracting distributed aspects and supporting multiple expertise.
The document discusses various patterns for generative programming including parser generation. It describes using a context-free grammar as input to automatically generate a parser. The key steps are:
1. Define regular expressions for tokens and context-free productions for nonterminals
2. Generate code for the parser from the grammar
3. Write boilerplate code to execute the generated parser and feed it a token stream.
The overall approach is to specify language structure through a grammar and then generate artifacts like lexers and parsers that can recognize or operate on that language.
What is probabilistic programming? By analogy: if functional programming is programming with first-class functions and equational reasoning, probabilistic programming is programming with first-class distributions and Bayesian inference. All computable probability distributions can be encoded as probabilistic programs, and every probabilistic program represents a probability distribution.
What does it do? It gives a concise language for specifying complex, structured statistical models, and abstracts over the implementation details of exact and approximate inference algorithms. These models can be networked, causal, hierarchical, recursive, anything: the graph structure of the program is the generative structure of the distribution.
Who's interested? Cognitive scientists, statisticians, machine-learning specialists, and artificial-intelligence researchers.
1. The document discusses Transformational Generative Grammar, which is a theory of grammar developed by Noam Chomsky that uses transformations to relate deep and surface structures of sentences.
2. It defines key concepts of transformational grammar like deep structure, surface structure, and transformations. Deep structure is the underlying form of a sentence before rules are applied, and surface structure is the final spoken/heard form.
3. Examples of transformations provided include passive, extraposition, and various focusing transformations like end-focus that place important information at the end of sentences.
This document provides an overview of syntax and generative grammar. It defines syntax as the way words are arranged to show relationships of meaning within and between sentences. Grammar is defined as the art of writing, but is now used to study language. Generative grammar uses formal rules to generate an infinite set of grammatical sentences. It distinguishes between deep structure and surface structure. Tree diagrams are used to represent syntactic structures with symbols like S, NP, VP. Phrase structure rules, lexical rules, and movement rules are components of generative grammar. Complement phrases and recursion allow sentences to be embedded within other sentences.
Ubiquitous computing (ubicomp) refers to computers integrated into everyday objects and activities. The goal is to create an environment where connectivity between devices is always available but unobtrusive. Examples of ubicomp devices include digital audio players, RFID tags, smartphones, and interactive whiteboards. Mark Weiser is considered the father of ubiquitous computing and coined the term in the 1980s.
This document provides an overview of principles of programming languages. It discusses definitions of programming languages and why they are studied. It covers the history of major languages from 1951 to present. It describes different language paradigms like imperative, functional, logic-based, and object-oriented. It also discusses attributes of good languages, issues in language design and translation, and the structure and operation of computers.
This document provides an introduction to C# programming language. It outlines the goals of the introduction, provides background on .NET and C#, compares C# to Java, discusses networking namespaces in C#, and references additional resources. The key points covered include an overview of .NET, how to get started with a simple C# application, differences between C# and Java, and links for further reading.
The document discusses key concepts and best practices for code inspections, including using meaningful variable names, writing self-documenting code, treating constants as parameters, improving layout and readability, and following coding standards. It emphasizes that the goal of code inspections and analysis is to make code maintenance easier by ensuring the code is understandable and unambiguous. It also suggests considering tools that integrate with development environments to support automated code inspections and analysis.
This document provides an overview of the .NET framework and common type system. It discusses key concepts like value types, reference types, inheritance, polymorphism, interfaces, boxing and unboxing. It also covers working with types in .NET like type operators, conversions, casting and managing external types. The document is divided into multiple modules that cover topics such as the .NET framework architecture, common language runtime, deployment, and common type system fundamentals.
DSM is a higher level of CASE process, a way to model data structures and logic in domain concepts independent from programming languages and thus also include syntax details. The final source code in a desired programming language is derived automatically from these high concept models by using exact language generators.The whole process of Meta-modeling in the MetaEdit+ tool rotates around the Meta types represented together as GOPPRR
CS4443 - Modern Programming Language - I Lecture (1)Dilawar Khan
This document outlines a course on Modern Programming Language - I using C#. The course objectives are to understand .NET technology and learn and implement C# programming skills. The course outline covers topics such as C# language fundamentals, object-oriented programming, exceptions handling, and generics. The recommended textbooks are also listed. The first lecture introduces C#, the .NET framework including CLR, MSIL, JIT compilation. It also demonstrates a simple "Hello World" C# console application to illustrate namespaces, classes, and comments.
The document provides an overview of the Microsoft .NET Framework. It discusses how .NET aims to unite isolated web applications and make information available anytime through the use of web services, XML support, and rich development tools. The .NET Framework includes a Common Language Runtime that manages running code and supports multiple programming languages. It also includes various framework services like ASP.NET, ADO.NET, and Windows forms. The Common Language Specification allows different .NET languages to interoperate. Visual Studio .NET is the primary development tool for building .NET applications.
Domain Driven Design Big Picture Strategic PatternsMark Windholtz
The document discusses Domain-Driven Design (DDD), an approach to software development for complex problems. It provides an overview of DDD and strategic patterns for organizing large projects with multiple teams, such as defining bounded contexts and context maps. Context maps describe the relationships between models, including shared kernels, customer/supplier, and conformist relationships. The document emphasizes defining a ubiquitous language within each context and mapping contexts to understand integration strategies at a large scale.
This document discusses software product lines and product line architectures. It defines a software product line as a set of software systems that share a common set of features addressing a particular market segment. Product lines are developed from a common set of core assets in a prescribed way to reduce costs and increase reuse. A product line architecture is a common framework that standardizes components and maximizes reuse potential. It specifies common functionality and identifies variation points across related products. Variability management is important for providing flexibility without compromising commonality.
Embedded systems are application-specific systems that contain hardware and software tailored for a particular task. They have real-time constraints and include requirements for performance, reliability, and form factor. Models and architectures are used to represent embedded system designs at different levels of abstraction. Hardware/software partitioning is the process of deciding which subsystems are best implemented in hardware versus software to meet performance goals within constraints like size, power, and cost.
Embedded systems are application-specific systems that contain hardware and software tailored for a particular task. Models and architectures are used to represent embedded system designs at different levels of abstraction. Hardware/software partitioning is the process of deciding which functionality is implemented in hardware versus software to meet performance and other constraints. There are various approaches to partitioning including functional decomposition, allocation of components, and using metrics to evaluate different partitions. Specification languages are used to capture system functionality in a way that supports partitioning.
Keith Douglas Johnston has over 30 years of experience as a senior software engineer designing, developing, and testing software. He has expertise in C, C++, Ada, and other languages. His experience ranges from digital signal processors to supercomputers. He holds MS degrees in Computer Science and Health Physics and a BS in Physics/Mathematics. He has received recognition from Boeing and NASA for his work.
This document provides an overview of developing Android applications. It introduces key Android concepts like application components, intents, views and layouts. It discusses generating user interfaces in XML and code. It also covers practical matters like storage, packaging, resources and the application lifecycle. The document concludes by introducing the Android development toolchain, including the emulator, Eclipse plugin and debugging tools.
Ontimize is a declarative high-level framework designed for increasing developer productivity when building and implementing interactive enterprise application solutions.
The Role of the Software Architect (short version)Hayim Makabee
Talk at the First Israeli Conference on Software Architecture
http://www.iltam.org/sw-arch2014/
Abstract:
In this talk Hayim will present the practical aspects of the role of the Software Architect, including the architect's contribution at the diverse stages of the software development life cycle, and the cooperation with the diverse stakeholders: Developers, Team Leaders, Project Managers, QA and Technical Writers.
Bio: Hayim Makabee was born in Rio de Janeiro. He immigrated to Israel in 1992 and completed his M.Sc. studies on Computer Sciences at the Technion. Since then he worked for several hi-tech companies, including also some start-ups. Currently he is a Research Engineer at Yahoo! Labs Haifa. He is also a co-founder of the International Association of Software Architects in Israel.
Online experts offer Assignment help & Homework Help to students. custom writing services for C++ Programming Assignment help & C++ Programming Homework help. Our C++ Programming Online tutors are available for instant help for C++ Programming assignments & problems.
C++ Programming Homework help & C++ Programming tutors offer 24*7 services . Send your C++ Programming assignments at support@globalwebtutors.com or else upload it on the website. Instant Connect to us on live chat for C++ Programming assignment help & C++ Programming Homework help
Methodologies and flows for chip designDerek Pappas
This document discusses the benefits of using a Chip Specification Language (CSL) to automatically generate shared infrastructure elements across hardware, software, simulation, and verification domains for chip design. Key points include:
- CSL allows for a single specification of infrastructure that can be compiled to generate equivalent code for all domains, avoiding errors from manual generation and maintenance.
- Automatically generating infrastructure can reduce engineering time spent on repetitive tasks by 10-100x, allowing teams to focus on design.
- Shared infrastructure specified in CSL maintains consistency when changes are made, rather than requiring updates across different files and teams manually.
- CSL can generate test benches, vectors, and other elements to dramatically increase verification points
This chapter discusses software development security. It covers topics like programming concepts, compilers and interpreters, procedural vs object-oriented languages, application development methods like waterfall vs agile models, databases, object-oriented design, assessing software vulnerabilities, and artificial intelligence techniques. The key aspects are securing the entire software development lifecycle from initial planning through operation and disposal, using secure coding practices, testing for vulnerabilities, and continually improving processes.
This document provides an overview of the .NET framework and Visual Basic .NET. It discusses how .NET improves on previous platforms by having a common language runtime (CLR) and class library, making development easier and code more portable. It also summarizes VB.NET features like being object-oriented and type-safe while retaining ease of use. Code compilation in VB.NET involves converting to MSIL rather than native machine code for portability.
This document discusses code generation in .NET. It begins by outlining some common problems developers face when dealing with large amounts of repetitive code. It then discusses various approaches to solving this problem, including hand coding everything, fully generic design, and using a combination of tools including code generation. The rest of the document discusses specific code generation tools for .NET like StringBuilder, CodeSnippets, XSLT, Reflection.Emit, EnvDTE, CodeDom, and T4. It also discusses pros and cons of each approach and provides examples of using code generation in different real world scenarios.
Similar to Generative Software Development. Overview and Examples (20)
This document discusses syntactic editor services including formatting, syntax coloring, and syntactic completion. It describes how syntactic completion can be provided generically based on a syntax definition. The document also discusses how context-free grammars can be extended with templates to specify formatting layout when pretty-printing abstract syntax trees to text. Templates are used to insert whitespace, line breaks, and indentation to produce readable output.
This document provides an overview of parsing in compiler construction. It discusses context-free grammars and how they are used to generate sentences and parse trees through derivations. It also covers ambiguity that can arise from grammars and various grammar transformations used to eliminate ambiguity, including defining associativity and priority. The dangling else problem is presented as an example of an ambiguous grammar.
This document provides an overview of the Lecture 2 on Declarative Syntax Definition for the CS4200 Compiler Construction course. The lecture covers the specification of syntax definition from which parsers can be derived, the perspective on declarative syntax definition using SDF, and reading material on the SDF3 syntax definition formalism and papers on testing syntax definitions and declarative syntax. It also discusses what syntax is, both in linguistics and programming languages, and how programs can be described in terms of syntactic categories and language constructs. An example Tiger program for solving the n-queens problem is presented to illustrate syntactic categories in Tiger.
This document provides an overview of the CS4200 Compiler Construction course at TU Delft. It discusses the course organization, structure, and assessment. The course is split into two parts - CS4200-A which covers concepts and techniques through lectures, papers, and homework assignments, and CS4200-B which involves building a compiler for a subset of Java as a semester-long project. Students will use the Spoofax language workbench to implement their compiler and will submit assignments through a private GitLab repository.
A Direct Semantics of Declarative Disambiguation RulesEelco Visser
This document discusses research into providing a direct semantics for declarative disambiguation of expression grammars. It aims to define what disambiguation rules mean, ensure they are safe and complete, and provide an effective implementation strategy. The document outlines key research questions around the meaning, safety, completeness and coverage of disambiguation rules. It also presents contributions around using subtree exclusion patterns to define safe and complete disambiguation for classes of expression grammars, and implementing this in SDF3.
Declarative Type System Specification with StatixEelco Visser
In this talk I present the design of Statix, a new constraint-based language for the executable specification of type systems. Statix specifications consist of predicates that define the well-formedness of language constructs in terms of built-in and user-defined constraints. Statix has a declarative semantics that defines whether a model satisfies a constraint. The operational semantics of Statix is defined as a sound constraint solving algorithm that searches for a solution for a constraint. The aim of the design is that Statix users can ignore the execution order of constraint solving and think in terms of the declarative semantics.
A distinctive feature of Statix is its use of scope graphs, a language parametric framework for the representation and querying of the name binding facts in programs. Since types depend on name resolution and name resolution may depend on types, it is typically not possible to construct the entire scope graph of a program before type constraint resolution. In (algorithmic) type system specifications this leads to explicit staging of the construction and querying of the type environment (class table, symbol table). Statix automatically stages the construction of the scope graph of a program such that queries are never executed when their answers may be affected by future scope graph extension. In the talk, I will explain the design of Statix by means of examples.
https://eelcovisser.org/post/309/declarative-type-system-specification-with-statix
Compiler Construction | Lecture 17 | Beyond Compiler ConstructionEelco Visser
Compiler construction techniques are applied beyond general-purpose languages through domain-specific languages (DSLs). The document discusses several DSLs developed using Spoofax including:
- WebDSL for web programming with sub-languages for entities, queries, templates, and access control.
- IceDust for modeling information systems with derived values computed on-demand, incrementally, or eventually consistently.
- PixieDust for client-side web programming with views as derived values updated incrementally.
- PIE for defining software build pipelines as tasks with dynamic dependencies computed incrementally.
The document also outlines several research challenges in compiler construction like high-level declarative language definition, verification of
Domain Specific Languages for Parallel Graph AnalytiX (PGX)Eelco Visser
This document discusses domain-specific languages (DSLs) for parallel graph analytics using PGX. It describes how DSLs allow users to implement graph algorithms and queries using high-level languages that are then compiled and optimized to run efficiently on PGX. Examples of DSL optimizations like multi-source breadth-first search are provided. The document also outlines the extensible compiler architecture used for DSLs, which can generate code for different backends like shared memory or distributed memory.
Compiler Construction | Lecture 15 | Memory ManagementEelco Visser
The document discusses different memory management techniques:
1. Reference counting counts the number of pointers to each record and deallocates records with a count of 0.
2. Mark and sweep marks all reachable records from program roots and sweeps unmarked records, adding them to a free list.
3. Copying collection copies reachable records to a "to" space, allowing the original "from" space to be freed without fragmentation.
4. Generational collection focuses collection on younger object generations more frequently to improve efficiency.
Compiler Construction | Lecture 14 | InterpretersEelco Visser
This document summarizes a lecture on interpreters for programming languages. It discusses how operational semantics can be used to define the meaning of a program through state transitions in an interpreter. It provides examples of defining the semantics of a simple language using DynSem, a domain-specific language for specifying operational semantics. DynSem specifications can be compiled to interpreters that execute programs in the defined language.
Compiler Construction | Lecture 13 | Code GenerationEelco Visser
The document discusses code generation and optimization techniques, describing compilation schemas that define how language constructs are translated to target code patterns, and covers topics like ensuring correctness of generated code through type checking and verification of static constraints on the target format. It also provides examples of compilation schemas for Tiger language constructs like arithmetic expressions and control flow and discusses generating nested functions.
Compiler Construction | Lecture 12 | Virtual MachinesEelco Visser
The document discusses the architecture of the Java Virtual Machine (JVM). It describes how the JVM uses threads, a stack, heap, and method area. It explains JVM control flow through bytecode instructions like goto, and how the operand stack is used to perform operations and hold method arguments and return values.
Compiler Construction | Lecture 9 | Constraint ResolutionEelco Visser
This document provides an overview of constraint resolution in the context of a compiler construction lecture. It discusses unification, which is the basis for many type inference and constraint solving approaches. It also describes separating type checking into constraint generation and constraint solving, and introduces a constraint language that integrates name resolution into constraint resolution through scope graph constraints. Finally, it discusses papers on further developments with this approach, including addressing expressiveness and staging issues in type systems through the Statix DSL for defining type systems.
Compiler Construction | Lecture 8 | Type ConstraintsEelco Visser
This lecture covers type checking with constraints. It introduces the NaBL2 meta-language for writing type specifications as constraint generators that map a program to constraints. The constraints are then solved to determine if a program is well-typed. NaBL2 supports defining name binding and type structures through scope graphs and constraints over names, types, and scopes. Examples show type checking patterns in NaBL2 including variables, functions, records, and name spaces.
Compiler Construction | Lecture 7 | Type CheckingEelco Visser
This document summarizes a lecture on type checking. It discusses using constraints to separate the language-specific type checking rules from the language-independent solving algorithm. Constraint-based type checking collects constraints as it traverses the AST, then solves the constraints in any order. This allows type information to be learned gradually and avoids issues with computation order.
Compiler Construction | Lecture 6 | Introduction to Static AnalysisEelco Visser
Lecture introducing the need for static analysis in addition to parsing, the complications caused by names, and an introduction to name resolution with scope graphs
Building RAG with self-deployed Milvus vector database and Snowpark Container...Zilliz
This talk will give hands-on advice on building RAG applications with an open-source Milvus database deployed as a docker container. We will also introduce the integration of Milvus with Snowpark Container Services.
Threats to mobile devices are more prevalent and increasing in scope and complexity. Users of mobile devices desire to take full advantage of the features
available on those devices, but many of the features provide convenience and capability but sacrifice security. This best practices guide outlines steps the users can take to better protect personal devices and information.
Introducing Milvus Lite: Easy-to-Install, Easy-to-Use vector database for you...Zilliz
Join us to introduce Milvus Lite, a vector database that can run on notebooks and laptops, share the same API with Milvus, and integrate with every popular GenAI framework. This webinar is perfect for developers seeking easy-to-use, well-integrated vector databases for their GenAI apps.
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...SOFTTECHHUB
The choice of an operating system plays a pivotal role in shaping our computing experience. For decades, Microsoft's Windows has dominated the market, offering a familiar and widely adopted platform for personal and professional use. However, as technological advancements continue to push the boundaries of innovation, alternative operating systems have emerged, challenging the status quo and offering users a fresh perspective on computing.
One such alternative that has garnered significant attention and acclaim is Nitrux Linux 3.5.0, a sleek, powerful, and user-friendly Linux distribution that promises to redefine the way we interact with our devices. With its focus on performance, security, and customization, Nitrux Linux presents a compelling case for those seeking to break free from the constraints of proprietary software and embrace the freedom and flexibility of open-source computing.
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Speck&Tech
ABSTRACT: A prima vista, un mattoncino Lego e la backdoor XZ potrebbero avere in comune il fatto di essere entrambi blocchi di costruzione, o dipendenze di progetti creativi e software. La realtà è che un mattoncino Lego e il caso della backdoor XZ hanno molto di più di tutto ciò in comune.
Partecipate alla presentazione per immergervi in una storia di interoperabilità, standard e formati aperti, per poi discutere del ruolo importante che i contributori hanno in una comunità open source sostenibile.
BIO: Sostenitrice del software libero e dei formati standard e aperti. È stata un membro attivo dei progetti Fedora e openSUSE e ha co-fondato l'Associazione LibreItalia dove è stata coinvolta in diversi eventi, migrazioni e formazione relativi a LibreOffice. In precedenza ha lavorato a migrazioni e corsi di formazione su LibreOffice per diverse amministrazioni pubbliche e privati. Da gennaio 2020 lavora in SUSE come Software Release Engineer per Uyuni e SUSE Manager e quando non segue la sua passione per i computer e per Geeko coltiva la sua curiosità per l'astronomia (da cui deriva il suo nickname deneb_alpha).
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slackshyamraj55
Discover the seamless integration of RPA (Robotic Process Automation), COMPOSER, and APM with AWS IDP enhanced with Slack notifications. Explore how these technologies converge to streamline workflows, optimize performance, and ensure secure access, all while leveraging the power of AWS IDP and real-time communication via Slack notifications.
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!SOFTTECHHUB
As the digital landscape continually evolves, operating systems play a critical role in shaping user experiences and productivity. The launch of Nitrux Linux 3.5.0 marks a significant milestone, offering a robust alternative to traditional systems such as Windows 11. This article delves into the essence of Nitrux Linux 3.5.0, exploring its unique features, advantages, and how it stands as a compelling choice for both casual users and tech enthusiasts.
20 Comprehensive Checklist of Designing and Developing a WebsitePixlogix Infotech
Dive into the world of Website Designing and Developing with Pixlogix! Looking to create a stunning online presence? Look no further! Our comprehensive checklist covers everything you need to know to craft a website that stands out. From user-friendly design to seamless functionality, we've got you covered. Don't miss out on this invaluable resource! Check out our checklist now at Pixlogix and start your journey towards a captivating online presence today.
Full-RAG: A modern architecture for hyper-personalizationZilliz
Mike Del Balso, CEO & Co-Founder at Tecton, presents "Full RAG," a novel approach to AI recommendation systems, aiming to push beyond the limitations of traditional models through a deep integration of contextual insights and real-time data, leveraging the Retrieval-Augmented Generation architecture. This talk will outline Full RAG's potential to significantly enhance personalization, address engineering challenges such as data management and model training, and introduce data enrichment with reranking as a key solution. Attendees will gain crucial insights into the importance of hyperpersonalization in AI, the capabilities of Full RAG for advanced personalization, and strategies for managing complex data integrations for deploying cutting-edge AI solutions.
Pushing the limits of ePRTC: 100ns holdover for 100 daysAdtran
At WSTS 2024, Alon Stern explored the topic of parametric holdover and explained how recent research findings can be implemented in real-world PNT networks to achieve 100 nanoseconds of accuracy for up to 100 days.
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024Neo4j
Neha Bajwa, Vice President of Product Marketing, Neo4j
Join us as we explore breakthrough innovations enabled by interconnected data and AI. Discover firsthand how organizations use relationships in data to uncover contextual insights and solve our most pressing challenges – from optimizing supply chains, detecting fraud, and improving customer experiences to accelerating drug discoveries.
For the full video of this presentation, please visit: https://www.edge-ai-vision.com/2024/06/building-and-scaling-ai-applications-with-the-nx-ai-manager-a-presentation-from-network-optix/
Robin van Emden, Senior Director of Data Science at Network Optix, presents the “Building and Scaling AI Applications with the Nx AI Manager,” tutorial at the May 2024 Embedded Vision Summit.
In this presentation, van Emden covers the basics of scaling edge AI solutions using the Nx tool kit. He emphasizes the process of developing AI models and deploying them globally. He also showcases the conversion of AI models and the creation of effective edge AI pipelines, with a focus on pre-processing, model conversion, selecting the appropriate inference engine for the target hardware and post-processing.
van Emden shows how Nx can simplify the developer’s life and facilitate a rapid transition from concept to production-ready applications.He provides valuable insights into developing scalable and efficient edge AI solutions, with a strong focus on practical implementation.
In the rapidly evolving landscape of technologies, XML continues to play a vital role in structuring, storing, and transporting data across diverse systems. The recent advancements in artificial intelligence (AI) present new methodologies for enhancing XML development workflows, introducing efficiency, automation, and intelligent capabilities. This presentation will outline the scope and perspective of utilizing AI in XML development. The potential benefits and the possible pitfalls will be highlighted, providing a balanced view of the subject.
We will explore the capabilities of AI in understanding XML markup languages and autonomously creating structured XML content. Additionally, we will examine the capacity of AI to enrich plain text with appropriate XML markup. Practical examples and methodological guidelines will be provided to elucidate how AI can be effectively prompted to interpret and generate accurate XML markup.
Further emphasis will be placed on the role of AI in developing XSLT, or schemas such as XSD and Schematron. We will address the techniques and strategies adopted to create prompts for generating code, explaining code, or refactoring the code, and the results achieved.
The discussion will extend to how AI can be used to transform XML content. In particular, the focus will be on the use of AI XPath extension functions in XSLT, Schematron, Schematron Quick Fixes, or for XML content refactoring.
The presentation aims to deliver a comprehensive overview of AI usage in XML development, providing attendees with the necessary knowledge to make informed decisions. Whether you’re at the early stages of adopting AI or considering integrating it in advanced XML development, this presentation will cover all levels of expertise.
By highlighting the potential advantages and challenges of integrating AI with XML development tools and languages, the presentation seeks to inspire thoughtful conversation around the future of XML development. We’ll not only delve into the technical aspects of AI-powered XML development but also discuss practical implications and possible future directions.
Generative Software Development. Overview and Examples
1. Generative Software Development
overview and examples
Eelco Visser
visser@acm.org
Universiteit Utrecht, Faculty of Science,
Department of Information and Computing Sciences,
Center for Software Technology
October 27, 2005
2. Generative Software Development
Generative software development is a system-family
approach, which focuses on automating the creation of
system-family members: a given system can be
automatically generated from a specification written in
one or more domain-specific languages.
K. Czarnecki. Overview of Generative Software Development. In J.-P. Bantre
et al. (Eds.): Unconventional Programming Paradigms (UPP) 2004, Mont
Saint-Michel, France, LNCS 3566, pp. 313-328, 2005
3. Outline
• Software system families
• Commonality and variability
• Domain engineering and application engineering
• Feature modeling
• Domain-specific languages
• Examples
• Generative programming
• Problem space
• Solution space
• Mapping
• Realizing generative software development
• Overview of techniques
• Example: assimilating embedded DSLs
• Risks
• Summary
4. Software System Families
Current research and practical experience suggest that
achieving significant progress with respect to software
reuse requires a paradigm shift towards modeling and
developing software system families rather than
individual systems.
Czarnecki 2005
5. Examples of Software System Families
• Compilers
• program representation, parsing, code generation, ...
• Web applications
• processing http requests, session management
• E-commerce systems
• products, user accounts, payment
• Office applications
• text processing
• Web browsers
• html rendering
• TV software
6. System Family Engineering
System-family engineering (product-line engineering)
seeks to exploit the commonalities among systems from
a given problem domain while managing the variabilities
among them in a systematic way.
Czarnecki 2005
7. Commonality and Variability
• E-commerce systems
• Commonalities: products, user accounts, payment, ...
• Variabilities: types of products, shipment methods, ...
• Web applications
• Commonalities: processing http requests, session management
• Variabilities: application workflow, page layout, ...
• Web browsers
• Commonalities: render HTML
• Variabilities: plugins for email, chatting, ...
8. Commonality and Variability
• Compilers
• Commonalities: program representation, parsing, code
generation, ...
• Variabilities: syntax and semantics of language
• Office applications
• Commonalities: text processing
• Variabilities: spellchecking, grammarchecking, ...
• TV software
• Commonalities: ?
• Variabilities: ?
9. System Family Engineering Process
system family engineering
=
domain engineering
+
application engineering
reusable assets
Domain engineering Application engineering
Domain analysis new requirements System requirements
Domain design System derivation
Domain implementation System tailoring
10. Domain Engineering = Development for Reuse
Development of reusable assets
• Reusable components, generic architectures, documentation
Software engineering process for a class of systems
• Domain analysis
• scope of family
• identify commonalities and variabilities
• Domain design
• common architecture
• plan creation of systems from reusable assets
• Domain implementation
• implementation of reusable assets
11. Feature Modeling
A method and notation to elicit and represent common and
variable features of the systems in a system family
• And: all subfeatures must be selected
• Alternative: only one subfeature can be selected
• Or: one or more can be selected
• Mandatory: features that are required
• Optional: features that are optional
Additional information
• constraints
• binding times
• default attribute values, default features
• stakeholders, priorities, etc.
12. Feature Modeling: Example
e-shop
payment taxCalculation shipping
creditCard debitCard electronicCheque addressResolution
country postalCode streetAddress
13. Feature Modeling: Alternative Notations
• Feature diagrams can be expressed as context-free grammars
• Feature selection is sentence generated by the grammar
e-shop : payment taxCalculation [shipping]
payment : paymentMethod+
paymentMethod : creditCard | debitCard | electronicCheque
taxCalculation : addressResolution
addressResolution : country | postalCode | streetAddres
• Expressivity of feature diagrams is restricted
• Features and other constraints can be expressed by means of
propositional formulae
See also D. Batory. Feature Models, Grammars, and Propositional Formulas. In
H. Obbink and K. Pohl (Eds.) SPLC 2005. LNCS 3714, pp. 7–20, 2005
14. Application Engineering = Development with Reuse
Build concrete applications using reusable assets
• Requirements = delta of generic system requirements
• System derivation: manual or automated construction of
system from reusable assets
Feedback to domain engineering
• Refine and adapt requirements
• Tailor reusable assets to application
15. Features vs Software Modules
Concrete features
• map to individual components
Crosscutting features
• can be implemented using aspect-oriented techniques
• Examples: logging, synchronization
Abstract features
• Also known as: non-functional requirements
• map to configuration of components and/or aspects
Grouping features
• Also known as: variation points
• map to common interface and plug-compatible components
16. Generative Software Development
Generative software development is a system-family
approach, which focuses on automating the creation of
system-family members: a given system can be
automatically generated from a specification written in
one or more domain-specific languages.
Czarnecki 2005
17. General Purpose Languages
Expressivity of general purpose languages is restricted to
• while(cond) { x = foo(y, z); }
• variable binding: storing values
• function calls: computing values
• control-flow: combining and choosing computations
This is a rather powerful and generic approach
• any computation can be expressed (Turing completeness)
• modularization facilities allow further abstraction
But it does not match application domains very well
18. Advantages of Domain-Specific Languages
• Domain-specific abstractions
• pre-defined abstractions for concepts in application domain
• Domain-specific concrete syntax
• natural notation for a domain
• Domain-specific error checking
• find and report errors based on domain knowledge and notation
• Domain-specific optimizations
• opportunities for optimizations based on domain knowledge
• Domain-specific tool support
• tools can be aware of domain
19. Domain-Specific Languages: Examples
Successful domain-specific languages exist for many domains
• Numerical computation
• Database queries
• Text search and analysis
• Symbolic computation
• Document transformation
• Workflow
• ...
20. Domain-Specific Languages: Arithmetic
x = c * y + z
• Notation and semantics based on long tradition in
mathematics
• General purpose language notation would require
x = plus(times(c, y), z)
x = z.plus(y.times(c))
x = c.times(y).plus(z)
• Compiler knows a lot about arithmetic
• optimizations (partial evaluation, strength reduction, ...)
• automatic coercions (int to real)
• exceptions
22. Domain-Specific Languages: Matrix Computation
A = c * B + C
• Now the elements of the assignment are matrices
• The expression ‘means’
for i = lb to ub do
A[i] = c * B[i] + C[i]
23. Domain-Specific Languages: Matrix Computation
A = c * B + C
• Now the elements of the assignment are matrices
• The expression ‘means’
for i = lb to ub do
A[i] = c * B[i] + C[i]
• General-purpose languages (C, C++, Java, ...) don’t
understand matrices
• ‘Mathematical’ languages such as Matlab and Octave do
• Matrix notation allows
• concise programs
• compiler may apply optimizations
24. Domain-Specific Languages: Database Queries
SELECT NAME
FROM ORDERS, INCLUDES, SUPPLIES
WHERE CUST = ’Chaudron’
AND ORDERS.O# = INCLUDUES.O#
AND INCLUDES.ITEM = SUPPLIES.ITEM
• SQL: notation for querying relational databases
• Abstracts from physical data structures of database
• Based on small set of relational algebra operators
• Allows efficient implementation of queries
• Queries can be checked against database schema
25. Domain-Specific Languages: Regular Expressions
^([a-z]+)/([A-Z][^/]+)/(.*)
• A regular expression describes or matches a set of strings,
according to certain syntax rules
• Used by many text editors and utilities to search and
manipulate bodies of text based on certain patterns.
• Many programming languages support regular expressions for
string manipulation.
• Notation abstracts from underlying finite automata
26. Domain-Specific Languages: Context-free Grammars
<postal-address> ::= <name-part> <street-address> <zip-part>
<personal-part> ::= <first-name> | <initial> "."
<name-part> ::= <personal-part> <last-name> [<jr-part>] <EOL>
| <personal-part> <name-part>
<street-address> ::= [<apt>] <house-num> <street-name> <EOL>
<zip-part> ::= <town-name> "," <state-code> <ZIP-code> <EOL>
• Describes syntax of a formal language
• Used to derive parsers that automatically recognize texts
• Writing parsers manually is complex and error-prone
27. Domain-Specific Languages: Rewrite Systems
|[ if 0 then s1 else s2 ]| -> |[ s2 ]|
|[ i + j ]| -> |[ k ]| where <add>(i,j) => k
• Rewrite rule replaces a matching term with another term
• Exhaustive application of rules reduces term to normal form
• Applications: symbolic computation, program transformation,
28. Domain-Specific Languages: Path Queries
/bookstore/book[price>35]/title
• XPATH path queries address parts of an XML document
• used in document transformation with XSLT
30. Domain-Specific Languages: Observations
• Domain-specific languages are everywhere
• DSL are sucessful when they cover a well-defined domain and
are based on solid foundations
• DSLs typically do not cover entire systems, but rather
well-defined parts/aspects of systems
31. Generative Software Development
Generative software development is a system-family
approach, which focuses on automating the creation of
system-family members: a given system can be
automatically generated from a specification written in
one or more domain-specific languages.
Czarnecki 2005
32. Generative Programming: Mapping Problems to Solutions
mapping
Problem space Solution space
Problem Space
• Set of domain specific abstractions
• Used to specify desired system family member
Solution Space
• Implementation oriented abstractions
• Can be instantiated to implement domain abstractions
33. Problem Space and Solution Space: Example
Problem Space
• Regular expressions
Solution Space
• Finite automata
• Expressed as transition table in code
Mapping
• Lexical analyzer generator (flex)
34. Mapping: Configuration View
Problem space
• domain-specific concepts and their features
• constraints: illegal feature combinations, default settings,
default dependencies
Specification
• selection of features for a specific system
Solution space
• implementation components, composed to create system
Mapping
• feature configuration mapped to component configuration
• mapping defined by construction rules and optimizations
Separation of spaces allows freedom of implementation
35. Configuration Example: Apache’s httpd.conf
Software composition
LoadModule file_cache_module modules/mod_file_cache.so
LoadModule mem_cache_module modules/mod_mem_cache.so
LoadModule cgi_module modules/mod_cgi.so
Configuration settings
<Directory /home/*/public_html>
AllowOverride FileInfo AuthConfig Limit
Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
<Limit GET POST OPTIONS>
Order allow,deny
Allow from all
</Limit>
<LimitExcept GET POST OPTIONS>
Order deny,allow
Deny from all
</LimitExcept>
</Directory>
Binding-time: configuration is processed at start-up time
36. Mapping: Transformational View
Problem space
• domain concepts captured by domain-specific language
Specification
• DSL program
Solution space
• implementation language
• components/libraries (‘run-time system’)
Mapping
• transformation from DSL to implementation language
37. Configuration vs Transformation
• Two views on mappings provide different perspectives
• Feature configuration defines a DSL with components as
implementation language
38. Combining Mappings
chaining
multiple problem spaces multiple solution spaces
alternative problem spaces alternative solution spaces
40. Realizing Generative Software Development
Requires techniques/technologies for creating
• Domain-specific languages
• Mappings
• Solution components
41. Realizing Domain-Specific Languages
Domain-specific languages come in many shapes and forms
• Textual languages
• Embedded in a programming language (MetaBorg)
• Graphical languages
• Wizards, GUIs
42. Realizing Mappings
Product line configurators
• map configuration file + components to system
Generators, implemented using
• Template and frame processors
• Transformation systems
• Multi-staged programming
• Program specialization
• Built-in meta-programming facility
Interpreters
• run-time interpretation of DSL program
44. Combining Techniques
Generative software development can be realized using various
combinations of techniques
Example scenario:
• Textual embedded language
• ‘Assimilation’ by program transformation
• Library for basic functionality of target programs
Example scenario:
• Graphical model language
• Graph transformations to map to aspect-oriented programs
• Aspects ‘inject’ code from model into base application
46. Assimilation of Embedded Languages
Embedding domain-specific languages
• Extend language with syntax for application domain
Examples
• Java + Swing Userinterface Language: Expressions reflect
hierarchy of Swing GUI objects
• Java + RegExps: Compile-time syntactic checks of regular
expressions, string rewrite rules
• Java + Java: Java programs that generate Java programs
Assimilation
• Meld embedded DSL code with host code
• Often requires local-to-global transformations
47. Assimilation of Embedded Languages
Embedding domain-specific languages
• Extend language with syntax for application domain
Concrete syntax for objects
Examples
syntactic abstractions for libraries (APIs)
• Java + Swing Userinterface Language: Expressions reflect
transformations to assimilate (and optimize)
hierarchy of Swing GUI objects
• Java + RegExps: Compile-time syntactic checks of regular
expressions, string rewrite rules
• Java + Java: Java programs that generate Java programs
Assimilation
• Meld embedded DSL code with host code
• Often requires local-to-global transformations
48. Assimilation of Embedded Languages
Embedding domain-specific languages
• Extend language with syntax for application domain
local to global transformation
Examples
generation of event handler class
• Java + Swing Userinterface regexp compiles
caching of Language: Expressions reflect
hierarchy of Swing GUI objects
adding class variable declarations
• Java + RegExps: Compile-time syntactic checks of regular
expressions, string rewrite rules
• Java + Java: Java programs that generate Java programs
Assimilation
• Meld embedded DSL code with host code
• Often requires local-to-global transformations
49. Example: Embedding Regular Expressions
re := str | alpha | re1 |re2 | re1 re2 | re* | re+
e := /re/ e | /re;f / x
t := regexp regexps
/re/e tests whether regular expression re matches value of e
50. Example: Embedding Regular Expressions
re := str | alpha | re1 |re2 | re1 re2 | re* | re+
e := /re/ e | /re;f / x
t := regexp regexps
/re/e tests whether regular expression re matches value of e
function isEmail(x : string) : int
begin
return / alpha+ @ (alpha+ .)+ alpha+ / x;
end
51. Example: Embedding Regular Expressions
re := str | alpha | re1 |re2 | re1 re2 | re* | re+
e := /re/ e | /re;f / x
t := regexp regexps
/re/e tests whether regular expression re matches value of e
function isEmail(x : string) : int
begin
return / alpha+ @ (alpha+ .)+ alpha+ / x;
end
/re;f/e tests if regular expression re matches a prefix of e, and
the suffix satisfies predicate f
52. Assimilating Regular Expression Matching
function match(x : string) : int
/ (a | b) c / x;
Desugar =
ReMch + ReStr + ReAlt + ReSeq + ReKle + once-AddDef
53. Assimilating Regular Expression Matching
function match(x : string) : int
/ (a | b) c / x;
Rewrite rule
L : t1 - t2 where s
replace fragment matching t1 with t2
Desugar =
ReMch + ReStr + ReAlt + ReSeq + ReKle + once-AddDef
ReMch :
|[ /re/ e ]| -
|[ begin
var x : string; x := e;
return /re; isEmpty/ x;
end ]|
where new = x
54. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return / (a | b) c; isEmpty / z;
end
Desugar =
ReMch + ReStr + ReAlt + ReSeq + ReKle + once-AddDef
ReMch :
|[ /re/ e ]| -
|[ begin
var x : string; x := e;
return /re; isEmpty/ x;
end ]|
where new = x
55. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return / (a | b) c; isEmpty / z;
end
ReSeq :
|[ /re1 re2 ; f/ x ]| - |[ /re1 ; g/ x ]|
where new = g
; add-def(||[
function g(a : string) : int /re2; f/ a;
]|)
add-def(|def) =
rules( AddDef :+ |[ def* ]| - |[ def def* ]| )
56. Assimilating Regular Expression Matching
Dynamic rules
rules( L : t1 - t2 )
defines new rewrite rule
inherits variable bindings from definition context
function match(x : string) : int
begin
var z : string; z := x; return / (a | b) c; isEmpty / z;
end
AddDef :
|[ def* ]| - |[ function k(a : string) : int /c; isEmpty/ a; def* ]|
ReSeq :
|[ /re1 re2 ; f/ x ]| - |[ /re1 ; g/ x ]|
where new = g
; add-def(||[
function g(a : string) : int /re2; f/ a;
]|)
add-def(|def) =
rules( AddDef :+ |[ def* ]| - |[ def def* ]| )
57. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return / (a | b) ; k / z;
end
AddDef :
|[ def* ]| - |[ function k(a : string) : int /c; isEmpty/ a; def* ]|
ReSeq :
|[ /re1 re2 ; f/ x ]| - |[ /re1 ; g/ x ]|
where new = g
; add-def(||[
function g(a : string) : int /re2; f/ a;
]|)
add-def(|def) =
rules( AddDef :+ |[ def* ]| - |[ def def* ]| )
58. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return / (a | b) ; k / z;
end
ReAlt :
|[ / (re1 | re2) ; f / x ]| - |[ (/re1;f/x) | (/re2;f/x) ]|
59. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return (/ a ; k / z) | (/ b ; k / z);
end
ReAlt :
|[ / (re1 | re2) ; f / x ]| - |[ (/re1;f/x) | (/re2;f/x) ]|
60. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x; return (/ a ; k / z) | (/ b ; k / z);
end
ReStr :
|[ /str ; f/ x ]| - |[ isPref(str, x) f(getSuf(str, x)) ]|
61. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x;
return (isPref(a,z) k(getSuf(a,z)))
| (isPref(b,z) k(getSuf(b,z)))
end
ReStr :
|[ /str ; f/ x ]| - |[ isPref(str, x) f(getSuf(str, x)) ]|
62. Assimilating Regular Expression Matching
function match(x : string) : int
begin
var z : string; z := x;
return (isPref(a,z) k(getSuf(a,z)))
| (isPref(b,z) k(getSuf(b,z)))
endAddDef :
|[ def* ]| - |[ function k(a : string) : int /c; isEmpty/ a; def* ]|
Desugar =
ReMch + ReStr + ReAlt + ReSeq + ReKle + once-AddDef
63. Assimilating Regular Expression Matching
function k(a : string) : int
begin
return /c; isEmpty/ a;
end
function match(x : string) : int
begin
var z : string; z := x
return (isPref(a,z) k(getSuf(a,z)))
| (isPref(b,z) k(getSuf(b,z)))
endAddDef :
|[ def* ]| - |[ function k(a : string) : int /c; isEmpty/ a; def* ]|
Desugar =
ReMch + ReStr + ReAlt + ReSeq + ReKle + once-AddDef
64. Assimilating Regular Expression Matching
function k(a : string) : int
begin
return /c; isEmpty/ a;
end
function match(x : string) : int
begin
var z : string; z := x
return (isPref(a,z) k(getSuf(a,z)))
| (isPref(b,z) k(getSuf(b,z)))
end
ReStr :
|[ /str ; f/ x ]| - |[ isPref(str, x) f(getSuf(str, x)) ]|
65. Assimilating Regular Expression Matching
function k(a : string) : int
begin
return isPref(c, a) isEmpty(getSuf(c, a));
end
function match(x : string) : int
begin
var z : string; z := x
return (isPref(a,z) k(getSuf(a,z)))
| (isPref(b,z) k(getSuf(b,z)))
end
ReStr :
|[ /str ; f/ x ]| - |[ isPref(str, x) f(getSuf(str, x)) ]|
66. Risks of Domain-Specific Languages
• Design and implementation effort
• implementing complete toolset for language is major effort
• Documentation
• tutorials, reference manual, implementation documentation
• Training
• need programmers that are skilled in using the language
• Maintenance
• of the language
• of DSL programs
• How does it fit in the existing work flow
• tool chain
• DSLs need abstraction/modularity features too
• DSL programs become large; reuse of parts needed
67. Conclusion
Summary
• Generative software development is encapsulation of domain
knowledge in generators and target components
• Domain-specific languages are the interface to this knowledge
• DSL programs can be seen as a configuration for the ‘solution
space’ components
Challenges
• Finding good formalizations and encapsulations of new
application domains
• A platform for cheap construction of DSLs and generators
• Integration of generators in workflow/toolchain
68. References
• K. Czarnecki. Overview of Generative Software Development.
In J.-P. Bantre et al. (Eds.): Unconventional Programming
Paradigms (UPP) 2004, Mont Saint-Michel, France, LNCS 3566,
pp. 313-328, 2005
• D. Batory. Feature Models, Grammars, and Propositional
Formulas. In H. Obbink and K. Pohl (Eds.) SPLC 2005. LNCS
3714, pp. 7–20, 2005
• M. Bravenboer and E. Visser. Concrete Syntax for Objects.
Domain-Specific Language Embedding and Assimilation
without Restrictions. In D. C. Schmidt, editor, Proceedings of the
19th ACM SIGPLAN Conference on Object-Oriented Programing,
Systems, Languages, and Applications (OOPSLA’04), pages
365–383, Vancouver, Canada, October 2004. ACM Press.
• E. Visser. Transformations for Abstractions. In J. Krinke and G.
Antoniol, editors, Fifth IEEE International Workshop on Source
Code Analysis and Manipulation (SCAM’05), Budapest, Hungary,
October 2005. IEEE Computer Society Press. (Keynote paper)
69. Further Studying
At Master Program Software Technology; Universiteit Utrecht
• Seminar on Software Generation and Configuration
• Master course on Program Transformation