Figure 5 - uploaded by Michael Engel
Content may be subject to copyright.
16550 UART Structure 

16550 UART Structure 

Source publication
Article
Full-text available
Aspect-oriented programming methods today have gained a significant following in the area of object-oriented high-level programming languages since their invention more than ten years ago. More recent developments have also found use cases for AOP in procedural programming languages operating at the system programming level. However, if one digs fu...

Context in source publication

Context 1
... can imagine more advanced types of join-points, e.g. including the execution of commonly used control structures like loops or case-statements. However, even these simple join-points can be quite useful when designing hardware. Section 4 describes a real-world example that makes use of these join-point types. Analogous to the aforementioned AOP languages, pointcuts for VHDL consist of a set of join-points combined using first- order logic formulae and wildcards to create a set of join- points. In the case of VHDL, its inherent concurrency has interesting consequences. Consider, for example, combining join- points at the setting of a signal using the “and” operator. In programming languages, a combination of two call(...) join-points using an && operator normally would not match anything. In VHDL, however, signals can be set concurrently, so a pointcut combining two such join-points would actually make sense. Additionally, it would be useful if one was able not only to describe single events, but rather to capture a sequence of events. Here, temporal logic could be used to create more complex pointcut descriptions[1]. This is also an interesting area for future research. Special care must also be taken when combining join- points that reside in concurrent vs. sequential parts of the VHDL code. This is discussed in detail below. As a first approach, the types of advice useful in an aspect- oriented extension of VHDL can be modeled after well- known advice types. However, due to the concurrent nature of VHDL, before and after advice are only well-defined in the context of processes. An around advice, however, can replace a signal assignment in a concurrent environment. Depending on the context, the proceed statement contained in the advice code will have to behave differently. If the related join-point is inside of a process, it will cause the original code (e.g., a signal assignment) to take place at the point in time proceed is executed. Outside of a process, however, timing is not relevant, thus proceed will create an additional, concurrent signal assignment. One important question is whether the code inside an advice is concurrent or sequential. If a pointcut for an advice includes join-points in concurrent structures, including concurrent code in the advice will result in additional, possibly conflicting, signal settings. Using a process inside that advice would be analogous to including the signal set at the related join-point in the sensitivity list of that process. If, however, a pointcut for an advice contains join-points in sequential VHDL code, then the execution of the advice code as a sequential process in the context of the original process containing the join-point is the only useful alternative. Overall, the most important differences between AOP in hardware description languages to classical aspect-oriented programming languages are caused by the implicit conocur- rency in HDLs (which may also be a problem for aspects in parallel programming languages). While a process is similar to a kind of advice, crosscutting concerns can still be found inside the code of a process. These properties are demon- strated using VHDL code in the following section. In analogy to the open source software movement, the approach of describing hardware using a HDL has led to an open hardware movement. This gives the chance to take a look at HDL implementations of complex circuits. Such an analysis was formerly impossible since hardware developers were guarding their intellectual property. 4 In this section, we verify our assumptions about crosscutting concerns by examining an implementation of a UART 5 as an example of a circuit used in real-world applications. A UART – Universal Asynchronous Receiver and Transmitter – is a circuit used for bit-serial communication between computer systems and peripheral devices like modems or printers. One common UART is the 16550, which is available as an open source VHDL implementation from QuickLogic, Inc. [11]. The 16550 UART consists of five interconnected entities (see fig. 5): transmitter, receiver, modem interface, bau- drate generator and interrupt controller. This structure is reflected in the VHDL source code, which consists of the files uart16550_baudgen , uart16550_intgen , uart16550_modem , uart16550_rx and uart16550_tx . In addition, the file uart 16550_top contains the top-level description of the circuit, i.e., its external bus interfaces. Each of the VHDL source files contains an entity part describing the components’ interface and an architecture part consisting of several parallel processes implementing the required functionality. One common problem of digital circuits is the handling of RESET conditions, in which the component is to be ini- tialised. This code is usually scattered over the various components of the design, each process that includes state, that has to be reset asynchronously has the RESET signal in its sensitity list, see fig. 6. Overall, there are 14 processes in the UART’s source code that are sensitive to the RESET signal contained in the source spread over five source code files. The code implementing the various reset functions can be factored out into an aspect. Fig. 7 shows a hypothetical VHDL AOP extension. Here, the pointcut describing the affected code positions has to match all functions that are sensitive to a reset. Since a process is started when any of the One important repository for open source hardware is 5 Universal Asynchronous Receiver and Transmitter signals in its sensitivity list change, this pointcut includes all of the functions that include RESET in their sensitivity list. The corresponding advice function can then implement the reset of all signals. Another crosscutting concern in the UART code is clock handling. There are eight different processes that depend on the system clock ( SCLK ). The processes are distributed over the source files for the receiver, transmitter, and the top level design file. In each of these processes, the level sensitivity of SCLK is checked via Here, one possible application for aspects is to change the clock base by introducing a local signal and creating a clock divider. When implementing this additional functionality, code at all of join-points, the eight processes that include the SCLK signal in their sensitivity list, is affected. The earliest mention of aspect-oriented approaches in hardware design can be found in Kiczales’ original paper on aspect-oriented programming[12]. Here, he discusses the Ptolemy project[7], which studies modeling, simulation, and design of concurrent, real-time, embedded systems with a focus on assembly of concurrent components. Interaction between heterogeneous components in Ptolemy is handled with concepts that are similar to aspects. In [6], AOP is applied to applications developed using SystemC [17] and AspectC++ [15]. Important system aspects like metrics measure, communication and cache policies are modelled. However, synthesizing real hardware from SystemC descriptions is difficult, so this approach is rather more useful in the area of simulation and verification. ADH [3] is a domain-specific HDL focusing on control modeling problems as well as the signal and image processing domain. A compiler translates the ADH descriptions into VHDL for synthesis. ADH supports the definition of pointcuts in hardware descriptions and before, after and around advice. However, the nature of the join-points in ADH does not take the inherent parallelism into account, it mostly concentrates on using AOP in sequential control flows for signal and image processing. In [18], aspect-oriented approaches to verification of digital systems using the e hardware description language [10] are described. While the paper gives a good overview of possible causes for crosscutting concerns in hardware description languages, the e language itself is rather limited in its sup- port for AOP. For example, there is no notion of pointcuts, since an advice may only relate to a single join-point. In addition, e is restricted to the verfication of hardware. Due to the lack of quantification, we consider this approach as highly-limited AOP – if at all. In [4], the authors describe a first idea to use AOP to for- mulate crosscutting concerns in hardware description languages. However, the only example given is the management of distributed clocks in hardware systems; an implementation does not seem to exist. The options approach [5] is the application of a concept from economy to the problem when to introduce AOP-based constructs in hardware design. However, the AOP concepts this decision relies on is based on the concepts presented in the paragraph above[4], so it should be re-evaluated when a more complete understanding of AOP for hardware design has evolved. The analysis of related work on aspects in hardware design has shown that there is considerable interest in applying AOP techniques in this domain. However, the existing approaches concentrate on design verification rather than ...

Citations

... In this sense, VHDL descriptions are somehow similar to a software source code files: they describe components structure and behavior using a language based on functional decomposition. Therefore, the handling of crosscutting concerns is found in many distinct elements, and hence, VHDL descriptions are subject to the same modularization issues related to crosscutting non-functional requirements [8,17,22]. ...
... Recently, an increasing number of research works propose the use of Aspect-Oriented Programming (AOP) in hardware design. The use of AOP in conjunct with VHDL language is analyzed in [8]. This work identifies some elements in VHDL which may be subject to aspects adaptations. ...
... As result, those authors indicate process and variable/signal assignments as possible join points in VHDL. These places are suitable for code injection, especially before, after and around each join point [8]. ...
Article
Full-text available
This paper discusses an approach to generate VHDL descriptions from high-level specifications, namely UML/MARTE models that include aspect-oriented semantics. Standard UML diagrams describe the handling of functional requirements, whereas crosscutting concerns associated with the non-functional requirements are handled by aspects. UML-to-VHDL transformation is performed automatically by a script-based code generation tool named GenERTiCA. For that, mapping rules scripts define how to generate VHDL constructs from model elements, including the implementation of aspects adaptations. The generated VHDL description does not require any manual modification, in order to be fully synthesized onto a FPGA device. Some case studies have been performed to evaluate the proposed approach, including examples of real systems implemented as a FPGA-based embedded system. Obtained results show an improvement in system design in terms of an increase in system performance as well as a better utilization of FPGA reconfigurable resources. Such positive results are related to a better modularization of components achieved by using the proposed high-level approach. These case studies demonstrate the practicability of full translation of platform-independent specifications into VHDL descriptions. Springer Nature SharedIt: https://rdcu.be/5xp1
... For this reason the aspect-oriented paradigm, when applied at the model level and with the existing support of underlying verification languages, can contribute to a more productive functional verification process. It has been reported that hardware verification testbenches lend themselves to aspect-oriented design as they commonly contain concerns that cannot be cleanly modularised with object-oriented methods alone [43,33,17,44]. Furthermore, aspect-oriented design complements the MBSE approach by facilitating the partitioning of models along aspect boundaries, providing a single view of each concern. ...
Article
The cost of correcting errors in the design of an embedded system’s hardware components can be higher than for its software components, making it important to test as early as possible. Testing hardware components before they are implemented involves verifying the design through either formal or more commonly, simulation-based functional verification. Performing functional verification of a hardware design requires software-based simulators and verification testbenches. However, the increasing complexity of embedded systems is contributing to testbenches that are progressively more difficult to understand, maintain, extend and reuse across projects. This paper presents an aspect-oriented domain-specific modelling language for the e hardware verification language that can be used as part of a model-based software engineering process. The modelling language is designed to produce well modularised models from which e code can be generated, thereby improving engineers ability to develop testbenches that can be more easily maintained, adapted and reused. We demonstrate the suitability of the modelling language through its application to a representative testbench from the automotive semiconductor industry.
... In contrast to pure software languages which offer extensive run-time support, the possibilities of aspects in conjunction with C++ based hardware design and verification languages are limited, especially when it comes to dynamic weaving. An overview about AOP in C++ can be found in [7], a summary about the use of aspects in hardware in [8]. ...
Article
As embedded systems incorporate more and more amounts of IP and embedded software the functional and nonfunctional verification task is one of the key bottlenecks in the design process. Despite proprietary design and verification languages such as IEEE-1800 SystemVerilog and IEEE-1647 e offer CDV functionalities neither SystemC or the SCV addon library contain these features. Moreover, as programming languages and verification paradigms of the hardware and software domain continue to converge the verification techniques and methodologies need to take account of that, e.g. by adaption of the aspect-oriented programming scheme. In this paper we describe an approach for enhancing the functional coverage collection in the SystemC ecosystem by means of aspects, allowing cross-cutting the concern of CDV verification in stand-alone aspects, increasing the overall verification productivity.
Conference Paper
This paper discusses an approach to generate VHDL descriptions from high-level specifications, specifically UML/MARTE models that include aspect-oriented semantics. Standard UML diagrams describe the handling of functional requirements, whereas crosscutting concerns associated with the non-functional requirements are handle by aspects. UML-to-VHDL transformation is performed automatically by a script-based code generation tool named GenERTiCA. For that, mapping rules scripts define how to generate VHDL constructs from model elements, including the implementation of aspects adaptations. The generated VHDL description does not require any manual modification, in order to be fully synthesized onto a FPGA device. Some case studies have been performed to evaluate the proposed approach, however, this paper discusses the line-following robot implemented as a FPGA-based embedded system. An improvement in system design has been obtained, namely an increase in system performance and a better utilization of FPGA reconfigurable resources. Such positive results are related to a better modularization of components achieved by using the proposed high-level approach.
Article
With the increasing complexity of digital hardware designs, hardware description languages are being pushed to higher levels of abstraction, thus allowing for the use of design artifacts which were previously exclusive to the software domain. In this paper we aimario by proposing artifacts and guidelines for hardware design at the register transfer level using object-oriented and aspect-oriented programming concepts. Our methodology is based on features provided by SystemC, a C++-based hardware description language, and leverages on its synthesizable subset in order to produce designs suitable for circuit synthesis. Our experimental results show that the introduction of aspect-oriented design artifacts results in an increased level of flexibility and reusability while yielding a circuit area overhead of only 2.5%2.5% when compared to non aspect-oriented designs.
Article
Developing testbenches for dynamic functional verification of hardware designs is a software-intensive process that lies on the critical path of electronic system design. The increasing capabilities of electronic components is contributing to the construction of complex verification environments that are increasingly difficult to understand, maintain, extend, and reuse across projects. Model-driven software engineering addresses issues of complexity, productivity, and code quality through the use of high-level system models and subsequent automatic transformations. Reasoning about verification testbench decomposition becomes simpler at higher levels of abstraction. In particular, the aspect-oriented paradigm, when applied at the model level, can minimize the overlap in functionality between modules, improving maintainability and reusability. This article presents an aspect-oriented model-driven engineering process and toolset for the development of hardware verification testbenches. We illustrate how this process and toolset supports modularized design and automatic transformation to verification environment-specific models and source code through an industry case study.
Article
Full-text available
In this paper we explore a SystemC-based hardware design method which uses aspect-oriented programming concepts. We have designed a synthesizable resource scheduler at register transfer level by using only features available in the SystemC synthesizable subset. The results show that aspect-oriented programming applied to digital hardware design provides a better separation of concerns at the cost of a negligible overhead.
Article
Hardware description languages are a promising field for the application of aspect technology. In a case study with the MB-Lite soft core CPU, which is an open, cycle accurate re-implementation of Xilinx' Microblaze processor, we show that crosscutting concerns in hardware structures actually exist. After discussing the semantic differences between programming languages and hardware description languages, we introduce our first version of AspectVHDL, an aspect-oriented extension of the popular hardware description language VHDL. The evaluation of an aspect-oriented variant of the MB-Lite CPU gives first evidence that using AspectVHDL for the implementation of crosscutting hardware concerns does not induce any costs in terms of chip space.