120 research outputs found
A Concurrent Language with a Uniform Treatment of Regions and Locks
A challenge for programming language research is to design and implement
multi-threaded low-level languages providing static guarantees for memory
safety and freedom from data races. Towards this goal, we present a concurrent
language employing safe region-based memory management and hierarchical locking
of regions. Both regions and locks are treated uniformly, and the language
supports ownership transfer, early deallocation of regions and early release of
locks in a safe manner
A Polyvariant Binding-Time Analysis for Off-line Partial Deduction
We study the notion of binding-time analysis for logic programs. We formalise
the unfolding aspect of an on-line partial deduction system as a Prolog
program. Using abstract interpretation, we collect information about the
run-time behaviour of the program. We use this information to make the control
decisions about the unfolding at analysis time and to turn the on-line system
into an off-line system. We report on some initial experiments.Comment: 19 pages (including appendix) Paper (without appendix) appeared in
Programming Languages and Systems, Proceedings of the European Symposium on
Programming (ESOP'98), Part of ETAPS'98 (Chris Hankin, eds.), LNCS, vol.
1381, 1998, pp. 27-4
Termination Proofs for Logic Programs with Tabling
Tabled logic programming is receiving increasing attention in the Logic
Programming community. It avoids many of the shortcomings of SLD execution and
provides a more flexible and often extremely efficient execution mechanism for
logic programs. In particular, tabled execution of logic programs terminates
more often than execution based on SLD-resolution. In this article, we
introduce two notions of universal termination of logic programming with
Tabling: quasi-termination and (the stronger notion of) LG-termination. We
present sufficient conditions for these two notions of termination, namely
quasi-acceptability and LG-acceptability, and we show that these conditions are
also necessary in case the tabling is well-chosen. Starting from these
conditions, we give modular termination proofs, i.e., proofs capable of
combining termination proofs of separate programs to obtain termination proofs
of combined programs. Finally, in the presence of mode information, we state
sufficient conditions which form the basis for automatically proving
termination in a constraint-based way.Comment: 48 pages, 6 figures, submitted to ACM Transactions on Computational
Logic (TOCL
Static Detection of Race Conditions in Erlang
We address the problem of detecting some commonly occurring kinds of race conditions in Erlang programs using static analysis. Our analysis is completely automatic, fast and scalable, and avoids false alarms by taking language characteristics into account. We have integrated our analysis in dialyzer, a commonly used tool for detecting software defects in Erlang programs which is part of Erlang/OTP, and evaluate its effectiveness and performance on a suite of widely used industrial and open source programs of considerable size. The analysis has detected a significant number of previously unknown race conditions
Test-Driven Development of Concurrent Programs using Concuerror
This paper advocates the test-driven development of concurrent Erlang programs in order to detect early and eliminate the vast majority of concurrency-related errors that may occur in their execution. To facilitate this task we have developed a tool, called Concuerror, that exhaustively explores process interleaving (possibly up to some preemption bound) and presents detailed interleaving information of any errors that occur. We describe in detail the use of Concuerror on a non-trivial concurrent Erlang program that we develop step by step in a test-driven fashion
La structuration de la révolution yéménite:Essai d’analyse d’un processus en marche
En s’intéressant aux mobilisations nées du processus révolutionnaire yéménite engagé en janvier 2011, cet article, né d’une longue expérience de terrain partagée, étudie les interactions entre des pratiques émergentes et les « propriétés structurelles des systèmes sociaux ». Il fait l’hypothèse d’une dualité du processus révolutionnaire qui apparaît comme produit par les acteurs qui le portent mais aussi comme contraint par une structure historique, sociale et politique. Il interroge ainsi la capacité de l’événement révolutionnaire à générer de l’innovation militante mais également à poindre lui-même du croisement entre les pratiques émergentes et la reprise en main du processus par des réseaux de mobilisation existants et des acteurs politiques déjà institutionnalisés.This article studies the mobilisations that have developed since the beginning of the Yemeni revolutionary process in January 2011. Built on shared and extensive fieldwork, it examines the interactions between emerging practices and the “structural properties of social systems”. It assumes the duality of the revolutionary process that appears both produced by the actors that carry it and constrained by a historical, social and political structure. This paper thereby questions the capability of the revolutionary event not only to generate innovations but also to emerge at the intersection of emerging practices and the process’ confiscation by former mobilisation networks and institutionalised political actors
Systematic Testing for Detecting Concurrency Errors in Erlang Programs
We present the techniques used in Concuerror, a systematic testing tool able to find and reproduce a wide class of concurrency errors in Erlang programs. We describe how we take advantage of the characteristics of Erlang's actor model of concurrency to selectively instrument the program under test and how we subsequently employ a stateless search strategy to systematically explore the state space of process interleaving sequences triggered by unit tests. To ameliorate the problem of combinatorial explosion, we propose a novel technique for avoiding process blocks and describe how we can effectively combine it with preemption bounding, a heuristic algorithm for reducing the number of explored interleaving sequences. We also briefly discuss issues related to soundness, completeness and effectiveness of techniques used by Concuerror
Contention Adapting Search Trees
Abstract-With multicores being ubiquitous, concurrent data structures are becoming increasingly important. This paper proposes a novel approach to concurrent data structure design where the data structure collects statistics about contention and adapts dynamically according to this statistics. We use this approach to create a contention adapting binary search tree (CA tree) that can be used to implement concurrent ordered sets and maps. Our experimental evaluation shows that CA trees scale similar to recently proposed algorithms on a big multicore machine on various scenarios with a larger set size, and outperform the same data structures in more contended scenarios and in sequential performance. We also show that CA trees are well suited for optimization with hardware lock elision. In short, we propose a practically useful and easy to implement and show correct concurrent search tree that naturally adapts to the level of contention. I. INTRODUCTION With multicores being widespread, the need for efficient concurrent data structures has increased. In this paper we propose a novel adaptive technique for creating concurrent data structures. Our technique collects statistics about contention in locks and does local adaptations dynamically to reduce the contention or to optimize for low contention. This is the first contribution of this paper. Previous research on adapting to the level of contention has focused on objects where access cannot be easily distibuted, such as locks We demonstrate the benefits of our contention adapting technique by describing and evaluating a data structure for concurrent ordered sets or maps. We call this data structure contention adapting search tree or CA tree for short. The design of CA trees is the second contribution of this paper. Curren
Purity in Erlang
Abstract. Motivated by a concrete goal, namely to extend Erlang with the ability to employ user-defined guards, we developed a parameterized static analysis tool called PURITY, that classifies functions as referentially transparent (i.e., sideeffect free with no dependency on the execution environment and never raising an exception), side-effect free with no dependencies but possibly raising exceptions, or side-effect free but with possible dependencies and possibly raising exceptions. We have applied PURITY on a large corpus of Erlang code bases and report experimental results showing the percentage of functions that the analysis definitely classifies in each category. Moreover, we discuss how our analysis has been incorporated on a development branch of the Erlang/OTP compiler in order to allow extending the language with user-defined guards
Precise explanation of success typing errors
Nowadays, many dynamic languages come with (some sort of) type
inference in order to detect type errors statically. Often, in order
not to unnecessarily reject programs which are allowed under a dynamic
type discipline, their type inference algorithms are based on
non-standard (i.e., not unification based) type inference algorithms.
Instead, they employ aggressive forwards and backwards propagation
of subtype constraints. Although such analyses are effective
in locating actual programming errors, the errors they report are
often extremely difficult for programmers to follow and convince
themselves of their validity. We have observed this phenomenon in
the context of Erlang: for a number of years now its implementation
comes with a static analysis tool called Dialyzer which, among
other software discrepancies, detects definite type errors (i.e., code
points that will result in a runtime error if executed) by inferring
success typings. In this work, we extend the analysis that infers
success typings, with infrastructure that maintains additional information
that can be used to provide precise (i.e., minimal) explanations
about the cause of a discrepancy reported by Dialyzer using
program slicing. We have implemented the techniques we describe
in a publicly available development branch of DialyzerSagonas, K.; Silva Galiana, JF.; Tamarit Muñoz, S. (2013). Precise explanation of success typing errors. En Proceeding PEPM '13 Proceedings of the ACM SIGPLAN 2013 workshop on Partial evaluation and program manipulation. Association for Computing Machinery (ACM). 33-42. doi:10.1145/2426890.2426897S334
- …