20 research outputs found

    A design pattern for optimizations in data intensive applications using ABS and JAVA 8

    Get PDF
    Cloud environments have become a standard method for enterprises to offer their applications by means of web services, data management systems, or simply renting out computing resources. In our previous work, we presented how we can use a modeling language together with the new features of JAVA 8 to overcome certain drawbacks of data structures and synchronization mechanisms in parallel applications. We extend this solution into a design pattern that allows application-specific optimizations in a distributed setting. We validate this integration using our previous case study of the Prime Sieve of Eratosthenes and illustrate the performance improvements in terms of speed-up and memory consumption

    A design pattern for optimizations in data intensive applications using ABS and JAVA 8

    Get PDF
    Cloud environments have become a standard method for enterprises to offer their applications by means of web services, data management systems, or simply renting out computing resources. In our previous work, we presented how we can use a modeling language together with the new features of JAVA 8 to overcome certain drawbacks of data structures and synchronization mechanisms in parallel applications. We extend this solution into a design pattern that allows application-specific optimizations in a distributed setting. We validate this integration using our previous case study of the Prime Sieve of Eratosthenes and illustrate the performance improvements in terms of speed-up and memory co

    Programs with continuations and linear logic

    Get PDF
    AbstractThe purpose of this paper is to investigate the programs with continuations in the framework of classical linear logic which can also be regarded as improvement of traditional classical logic. First, simply typed λ-calculus λ→c with continuation primitives is introduced. Second, a translation from λ→c to linear logic is given. Last, a correspondence between them is presented

    Towards Compatible and Interderivable Semantic Specifications for the Scheme Programming Language, Part I: Denotational Semantics, Natural Semantics, and Abstract Machines

    Get PDF
    We derive two big-step abstract machines, a natural semantics, and the valuation function of a denotational semantics based on the small-step abstract machine for Core Scheme presented by Clinger at PLDI'98. Starting from a functional implementation of this small-step abstract machine, (1) we fuse its transition function with its driver loop, obtaining the functional implementation of a big-step abstract machine; (2) we adjust this big-step abstract machine so that it is in defunctionalized form, obtaining the functional implementation of a second big-step abstract machine; (3) we refunctionalize this adjusted abstract machine, obtaining the functional implementation of a natural semantics in continuation style; and (4) we closure-unconvert this natural semantics, obtaining a compositional continuation-passing evaluation function which we identify as the functional implementation of a denotational semantics in continuation style. We then compare this valuation function with that of Clinger's original denotational semantics of Scheme

    TurKit: Human Computation Algorithms on Mechanical Turk

    Get PDF
    Mechanical Turk (MTurk) provides an on-demand source of human computation. This provides a tremendous opportunity to explore algorithms which incorporate human computation as a function call. However, various systems challenges make this difficult in practice, and most uses of MTurk post large numbers of independent tasks. TurKit is a toolkit for prototyping and exploring algorithmic human computation, while maintaining a straight-forward imperative programming style. We present the crash-and-rerun programming model that makes TurKit possible, along with a variety of applications for human computation algorithms. We also present case studies of TurKit used for real experiments across different fields.Xerox CorporationNational Science Foundation (U.S.) (Grant No. IIS- 0447800)Quanta ComputerMassachusetts Institute of Technology. Center for Collective Intelligenc

    Continuation-Passing C: compiling threads to events through continuations

    Get PDF
    In this paper, we introduce Continuation Passing C (CPC), a programming language for concurrent systems in which native and cooperative threads are unified and presented to the programmer as a single abstraction. The CPC compiler uses a compilation technique, based on the CPS transform, that yields efficient code and an extremely lightweight representation for contexts. We provide a proof of the correctness of our compilation scheme. We show in particular that lambda-lifting, a common compilation technique for functional languages, is also correct in an imperative language like C, under some conditions enforced by the CPC compiler. The current CPC compiler is mature enough to write substantial programs such as Hekate, a highly concurrent BitTorrent seeder. Our benchmark results show that CPC is as efficient, while using significantly less space, as the most efficient thread libraries available.Comment: Higher-Order and Symbolic Computation (2012). arXiv admin note: substantial text overlap with arXiv:1202.324

    Concurrency in Android development – Kotlin Coroutines and RxJava

    Get PDF
    A faulty concurrency system may have an impact in the user experience of the software product and consequently to the company that owns that product. The main goal of this research is to understand the impact of concurrency in Android development and further help developers/companies to discretise the best approaches for concurrency. The research initially centres on the importance of concurrency in Android applications as well as the main approaches for concurrency/threading in Android development. It further illustrates why some asynchronous programming approaches do not fit modern Android development. This allowed the research to concentrate on the most relevant approaches to concurrency and consequently produce more pertinent results for the current state of Android development. After acknowledging Kotlin Coroutines and RxJava as the most relevant approaches to concurrency for Android (at the time of writing this document), this research moved on with the development of a case study application. This application was implemented using both Kotlin Coroutines and RxJava while reusing as much code as possible. There is a single module dedicated to the main user interface of the application and two modules (one for Kotlin Coroutines and one for RxJava) dedicated to concurrently run the necessary steps for each feature and further propagating the necessary data to the user interface. This allowed a clear separation of the specific code needed to perform the same features with Kotlin Coroutines and RxJava, facilitating its later comparison. The design of this application and its features required prior assessment of common use cases for concurrency in Android to form a fitting case study. With the intent of assessing the impact of using Kotlin Coroutines and RxJava in Android applications, we discretised the main software quality attributes to consider for Android development. By taking this step, we were able to focus mainly on the Performance and Maintainability of an Android application and understand how the usage of both Kotlin Coroutines and RxJava affects these attributes. The impact of each library in the performance and maintainability of an Android application was measured using software metrics that were provided by a combination of static analysis, benchmarks, and profiling tests. The process of designing the set of tests, setting up the required tools and the overall development of the test environment for this research is also explored in this document. The results for Kotlin Coroutines and RxJava were then illustrated, compared, and interpreted to fulfil our objective of understanding if, at the time of writing this document, there is a more sensible approach to concurrency for Android development according to our set of tests. The results for our set of tests and case study application revealed that RxJava and Kotlin Coroutines do not differently compromise the performance and maintainability of an Android application, for what developers and companies should not be limited when choosing between these libraries

    Partial Aborts for Transactions via First Class Continuations

    Get PDF
    Software transactional memory (STM) has proven to be a useful abstraction for developing concurrent applications where programmers denote transactions with an atomic construct that delimits a collection of reads and writes to shared mutable references. The runtime system then guarantees that all transactions are observed to execute atomically with respect to each other. Traditionally, when the runtime system detects that one transaction conflicts with another, it aborts one of the transactions and restarts its execution from the beginning. This can lead to problems with both execution time and throughput. This thesis presents a novel approach that uses first-class continuations to restart a conflicting transaction at the point of a conflict, avoiding the re-execution of any work from the beginning of the transaction that has not been compromised. In practice, this allows transactions to complete more quickly, decreasing execution time and increasing throughput. The ideas presented in this thesis have been implemented in the context of the Manticore project, an ML-family language with support for parallelism and concurrency. Crucially, this work relies on constant-time continuation capturing via a continuation-passing-style (CPS) transformation and heap-allocated continuations. The partial abort scheme has been implemented as a part of three modern STM implementations: TL2, TinySTM, and NOrec. Experimental results show that, while no base STM implementation is universally best, each partial-abort implementation compares favorably to its full-abort counterpart. In addition to an implementation, this thesis presents a formal semantics for partial aborts. A proof of correctness is given by relating the partial-abort semantics to an analogous full-abort semantics via a simulation. All proofs have been formally verified using the Coq Theorem Prover
    corecore