58 research outputs found

    A Study of Concurrency Bugs and Advanced Development Support for Actor-based Programs

    Full text link
    The actor model is an attractive foundation for developing concurrent applications because actors are isolated concurrent entities that communicate through asynchronous messages and do not share state. Thereby, they avoid concurrency bugs such as data races, but are not immune to concurrency bugs in general. This study taxonomizes concurrency bugs in actor-based programs reported in literature. Furthermore, it analyzes the bugs to identify the patterns causing them as well as their observable behavior. Based on this taxonomy, we further analyze the literature and find that current approaches to static analysis and testing focus on communication deadlocks and message protocol violations. However, they do not provide solutions to identify livelocks and behavioral deadlocks. The insights obtained in this study can be used to improve debugging support for actor-based programs with new debugging techniques to identify the root cause of complex concurrency bugs.Comment: - Submitted for review - Removed section 6 "Research Roadmap for Debuggers", its content was summarized in the Future Work section - Added references for section 1, section 3, section 4.3 and section 5.1 - Updated citation

    Detection of Asynchronous Message Passing Errors Using Static Analysis

    Get PDF
    Concurrent programming is hard and prone to subtle errors. In this paper we present a static analysis that is able to detect some commonly occurring kinds of message passing errors in languages with dynamic process creation and communication based on asynchronous message passing. Our analysis is completely automatic, fast, and strikes a proper balance between soundness and completeness: it is effective in detecting errors and avoids false alarms by computing a close approximation of the interprocess communication topology of programs. We have integrated our analysis in dialyzer, a widely used tool for detecting software defects in Erlang programs, and demonstrate its effectiveness on libraries and applications of considerable size. Despite the fact that these applications have been developed over a long period of time and are reasonably well-tested, our analysis has managed to detect a significant number of previously unknown message passing errors in their code

    Revisiting Actor Programming in C++

    Full text link
    The actor model of computation has gained significant popularity over the last decade. Its high level of abstraction makes it appealing for concurrent applications in parallel and distributed systems. However, designing a real-world actor framework that subsumes full scalability, strong reliability, and high resource efficiency requires many conceptual and algorithmic additives to the original model. In this paper, we report on designing and building CAF, the "C++ Actor Framework". CAF targets at providing a concurrent and distributed native environment for scaling up to very large, high-performance applications, and equally well down to small constrained systems. We present the key specifications and design concepts---in particular a message-transparent architecture, type-safe message interfaces, and pattern matching facilities---that make native actors a viable approach for many robust, elastic, and highly distributed developments. We demonstrate the feasibility of CAF in three scenarios: first for elastic, upscaling environments, second for including heterogeneous hardware like GPGPUs, and third for distributed runtime systems. Extensive performance evaluations indicate ideal runtime behaviour for up to 64 cores at very low memory footprint, or in the presence of GPUs. In these tests, CAF continuously outperforms the competing actor environments Erlang, Charm++, SalsaLite, Scala, ActorFoundry, and even the OpenMPI.Comment: 33 page

    Dynamically typed languages

    Get PDF
    Dynamically typed languages such as Python and Ruby have experienced a rapid grown in popularity in recent times. However, there is much confusion as to what makes these languages interesting relative to statically typed languages, and little knowledge of their rich history. In this chapter I explore the general topic of dynamically typed languages, how they differ from statically typed languages, their history, and their defining features

    Behaviour Preservation across Code Versions in Erlang

    Full text link
    [EN] In any alive and nontrivial program, the source code naturally evolves along the lifecycle for many reasons such as the implementation of new functionality, the optimization of a bottleneck, or the refactoring of an obscure function. Frequently, these code changes affect various different functions and modules, so it can be difficult to know whether the correct behaviour of the previous version has been preserved in the new version. In this paper, we face this problem in the context of the Erlang language, where most developers rely on a previously defined test suite to check the behaviour preservation. We propose an alternative approach to automatically obtain a test suite that specifically focusses on comparing the old and new versions of the code. Our test case generation is directed by a sophisticated combination of several already existing tools such as TypEr, CutEr, and PropEr; and it introduces novel ideas such as allowing the programmer to choose one or more expressions of interest that must preserve the behaviour, or the recording of the sequences of values to which those expressions are evaluated. All the presented work has been implemented in an open-source tool that is publicly available on GitHub.This work has been partially supported by MINECO/AEI/FEDER (EU) under Grant TIN2016-76843-C4-1-R and by Generalitat Valenciana under Grant PROMETEO-II/2015/013 (SmartLogic). Salvador Tamarit was partially supported by Conselleria de Educacion, Investigacion, Cultura y Deporte de la Generalitat Valenciana, under Grant APOSTD/2016/036.Insa Cabrera, D.; Pérez-Rubio, S.; Silva, J.; Tamarit Muñoz, S. (2018). Behaviour Preservation across Code Versions in Erlang. Scientific Programming. 2018:9251762:1-9251762:42. https://doi.org/10.1155/2018/9251762S9251762:19251762:42201

    Monikieliohjelmointi Web-sovelluskehityksessä

    Get PDF
    Different programming languages are used to solve different problem domains. Front-end code standards and best practices are used to separate presentation, content and behavior. Architectural approaches like three-tier client-server architecture present user interface, business logic and data access as independent modules to develop and maintain. The idea of polyglot programming is to combine and utilize the best solutions from different programming languages and paradigms. Therefore, polyglot programming has the potential to improve web development in various areas. Web development has always been polyglot. Polyglot system has two essential aspects, the platform used for the integration and the programming languages supported. The recent rise of non-Java programming languages running on the Java Virtual Machine has created a favorable environment for polyglot programming. The possibility to use more expressive and succinct programming languages with existing solutions has proven to be essential in web development. An example web project was implemented to study the observations in practice. The project was implemented in both Java and Groovy as a server-side web application and also with Vert.x and AngularJS as a client-side single-page application. Also an additional Groovy implementation with Java legacy domain model was implemented to study programming language interoperability on the Java Virtual Machine. The results were evaluated against related work consisting two project implementations and three case study projects presented also in the context of polyglot programming in web development. Polyglot programming can enhance web development, because different programming languages and frameworks promise an increase in productivity, reduced amount of code and improved code quality that together promote better maintainability. Although polyglot programming has a steep learning curve that affects on required knowledge, maintainability, and tool support.Erilaisia ongelma-alueita pyritään ratkaisemaan käyttäen eri ohjelmointikieliä. Esimerkiksi Frontend-ohjelmointikäytäntöjä noudattamalla voidaan erottaa esitys-, sisältö ja toimintalogiikka toisistaan. Lisäksi arkkitehtuuriratkaisut, kuten kolmikerrosarkkitehtuuri, jakavat käyttöliittymän, toimintalogiikan ja tietovarastojen käytön itsenäisiksi, mahdollisesti toisistaan erillään kehitettäviksi ja ylläpidettäviksi moduuleiksi. Monikieliohjelmoinnin ideana on yhdistää ja hyödyntää ohjelmointikielten ja ohjelmointiparadigmojen parhaat ratkaisut. Tästä syystä monikieliohjelmointi voi mahdollisesti parantaa Web-sovelluskehitystä useilla eri osa-alueilla. Monikielisyys on aina ollut osa Web-sovelluskehitystä. Monikielisessä järjestelmässä on kaksi olennaista ominaisuutta, käytettävissä oleva sovelluskehitysalusta sekä käytettävissä olevat ohjelmointikielet. Viimeaikainen kehitys ohjelmointikielissä Java-virtuaalikoneella on luonut suotuisan ympäristön monikieliohjelmoinnille. Mahdollisuus käyttää kuvaavampia ja ytimekkäämpiä ohjelmointikieliä olemassa olevien ratkaisujen tukena on osoittautunut tärkeäksi. Työn yhteydessä toteutettua esimerkkiprojektia käytettiin tarkastelemaan tehtyjä havaintoja käytännössä. Projekti toteutettiin sekä Java- että Groovy-ohjelmointikielellä palvelinpuolen Web-sovelluksena sekä Vert.x ja AngularJS Web-sovelluskehyksiä hyödyntäen asiakaspuolen yhden sivun Web-sovelluksena. Lisäksi ohjelmointikielten yhteentoimivuutta tutkittiin tekemällä Groovy-ohjelmointikielellä toteutus, joka hyödynsi valmista Java-toteutuksen toimialueen mallinnusta. Monikieliohjelmointi voi tehdä Web-sovelluskehityksestä kannattavampaa. Eri ohjelmointikielet ja ohjelmistokehykset lupaavat lisätä tuottavuutta, vähentää tarvittavan koodin määrää, sekä parantaa koodin laatua, parantaen näin samalla ylläpidettävyyttä. On kuitenkin tärkeää huomata se, että monikieliohjelmointi kasvattaa tarvittavan tiedon määrä, mikä vaikuttaa suoraan ylläpidettävyyteen sekä tarvittavaan työkalutukeen

    On Preserving the Behavior in Software Refactoring: A Systematic Mapping Study

    Get PDF
    Context: Refactoring is the art of modifying the design of a system without altering its behavior. The idea is to reorganize variables, classes and methods to facilitate their future adaptations and comprehension. As the concept of behavior preservation is fundamental for refactoring, several studies, using formal verification, language transformation and dynamic analysis, have been proposed to monitor the execution of refactoring operations and their impact on the program semantics. However, there is no existing study that examines the available behavior preservation strategies for each refactoring operation. Objective: This paper identifies behavior preservation approaches in the research literature. Method: We conduct, in this paper, a systematic mapping study, to capture all existing behavior preservation approaches that we classify based on several criteria including their methodology, applicability, and their degree of automation. Results: The results indicate that several behavior preservation approaches have been proposed in the literature. The approaches vary between using formalisms and techniques, developing automatic refactoring safety tools, and performing a manual analysis of the source code. Conclusion: Our taxonomy reveals that there exist some types of refactoring operations whose behavior preservation is under-researched. Our classification also indicates that several possible strategies can be combined to better detect any violation of the program semantics
    corecore