2,794 research outputs found

    A distributed Real-Time Java system based on CSP

    Get PDF
    CSP is a fundamental concept for developing software for distributed real time systems. The CSP paradigm constitutes a natural addition to object orientation and offers higher order multithreading constructs. The CSP channel concept that has been implemented in Java deals with single- and multi-processor environments and also takes care of the real time priority scheduling requirements. For this, the notion of priority and scheduling has been carefully examined and as a result it was reasoned that priority scheduling should be attached to the communicating channels rather than to the processes. In association with channels, a priority based parallel construct is developed for composing processes: hiding threads and priority indexing from the user. This approach simplifies the use of priorities for the object oriented paradigm. Moreover, in the proposed system, the notion of scheduling is no longer connected to the operating system but has become part of the application instead

    Slicing of Aspect-Oriented Software and Its Application to Software Refactoring

    Get PDF
    This thesis first presents some program slicing techniques for Aspect-Oriented Programs (AOPs) and then presents a technique for refactoring of software using the proposed slicing technique. Main aim of all the proposed slicing algorithms in this thesis is to compute accurate and precise dynamic slices of AOPs. In order to compute the slices of aspect-oriented programs, first we extend the System Dependence Graph (SDG) for Object-Oriented Programs (OOPs) to handle AOPs. We have named the extended SDG Extended Aspect-Oriented System Dependence Graph (EAOSDG). The EAOSDG successfully represents different aspect- oriented features such as class representation, method invocation, inheritance, aspect declaration, point-cuts, advices etc. The EAOSDG of an aspect-oriented program consists of System Dependence Graph (SDG) for the non-aspect code, a group of Aspect-Oriented Dependence Graphs (ADGs) for aspect code and some additional dependence edges that are used to connect the SDG of the non-aspect code (base code) to ADG of the aspect code. Then, we propose an extended two-phase algorithm to compute the static slices of AOPs, using the proposed EAOSDG. Subsequently, we present a context-sensitive slicing algorithm to compute the dynamic slices of AOPs, using the proposed EAOSDG. The context-sensitivity makes the computed slice more precise and accurate. We have developed a slicer to implement our proposed algorithms. We have compared the performance of extended two-phase algorithm and context-sensitive algorithm, in terms of the average slice extraction time. We have considered five open source projects for comparison of slicing algorithms. We have observed that the context-sensitive algorithm computes the slices faster than the extended-two phase algorithm. Next, we extends our intermediate representation (EAOSDG) to be able to represent concurrent aspect-oriented programs. We have named this intermediate representation Multithreaded Aspect-Oriented Dependence Graph (MAODG). Our MAODG correcly represents the concurrency dependencies in concurrent AOPs. Then, we extend our context-sensitive dynamic slicing technique to handle concurrent AOPs having multiple threads. We have named our algorithm Context-Sensitive Concurrent Aspect (CSCA) slicing algorithm. Due to the presence of inter-thread synchronization and communication dependencies, some control and data flows in the threads become interdependent. This interdependency causes difficulty in finding accurate slices of concurrent AOPs. Our algorithm takes the MAODG of the concurrent AOP and a slicing criterion as input and vii computes the dynamic slice for the given concurrent AOP. We have developed a slicer Concurrent AspectJ slicer to implement our proposed CSCA algorithm. We have compared CSCA algorithm with two other existing algorithms using five case studies. The experiment shows that, our proposed CSCA algorithm computes precise slices in less time as compared to the other two existing algorithms. Further, we propose an approach for dynamic slicing of distributed AOPs. We first represent distributed aspect-oriented program using dependence based intermediate representation which we have named Distributed Aspect Dependence Graph (DADG). Based on the DADG, we present a slicing algorithm Parallel Context-sensitive Dynamic Slicing (PCDS) algorithm for distributed AOPs. We introduce parallelism in our algorithm to make slice computation faster. We have developed a tool called D-AspectJ slicer to implement the PCDS algorithm. The proposed slicing algorithm is compared with two other existing algorithms using seven case studies. The experimentation shows that our proposed PCDS algorithm generates smaller slices in less time as compared to the other two existing algorithms. Finally, we present a technique for software refactoring using program slicing. We use slice-based cohesion metrics to identify the target methods of a software that require refactoring. After identifying the target methods, we use program slicing to divide the target method into two parts. Then, we use the concept of aspects to alter the code structure in a manner that does not change the external behavior of the original module. We have implemented our proposed refactoring technique and evaluated its effectiveness through eleven case studies. We have also evaluated the effect of our proposed refactoring technique based on an open source code coverage tool EclEmm

    Dynamic Slicing of Object-Oriented Programs

    Get PDF
    Software maintenance activity is one of the most important part of software development cycle. Certain regions of a program cause more damage than other regions resulting in errors, if they contain bugs. So, it is important to debug and find those areas. We use slicing criteria to obtain a static backward slice of a program to find these areas. An intermediate graphical representation is obtained for an input source program such as the Program Dependence Graph, the Class Dependence Graph and the System Dependence Graph. Slicing is performed on the System Dependence Graph using a two pass graph reachability algorithm proposed by Horwitz[3], and a static backward slice is obtained. After obtaining static slice, dynamic slice is calculated for the given input variable using an algorithm where in a statement, a set of variables and the input values for these variables are taken as input and a dynamic slice is obtained

    Safe Concurrency Introduction through Slicing

    Get PDF
    Traditional refactoring is about modifying the structure of existing code without changing its behaviour, but with the aim of making code easier to understand, modify, or reuse. In this paper, we introduce three novel refactorings for retrofitting concurrency to Erlang applications, and demonstrate how the use of program slicing makes the automation of these refactorings possible

    Sound Static Deadlock Analysis for C/Pthreads (Extended Version)

    Full text link
    We present a static deadlock analysis approach for C/pthreads. The design of our method has been guided by the requirement to analyse real-world code. Our approach is sound (i.e., misses no deadlocks) for programs that have defined behaviour according to the C standard, and precise enough to prove deadlock-freedom for a large number of programs. The method consists of a pipeline of several analyses that build on a new context- and thread-sensitive abstract interpretation framework. We further present a lightweight dependency analysis to identify statements relevant to deadlock analysis and thus speed up the overall analysis. In our experimental evaluation, we succeeded to prove deadlock-freedom for 262 programs from the Debian GNU/Linux distribution with in total 2.6 MLOC in less than 11 hours
    corecore