Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/2737924.2737996acmconferencesArticle/Chapter ViewAbstractPublication PagespldiConference Proceedingsconference-collections
research-article

Asynchronous programming, analysis and testing with state machines

Published: 03 June 2015 Publication History
  • Get Citation Alerts
  • Abstract

    Programming efficient asynchronous systems is challenging because it can often be hard to express the design declaratively, or to defend against data races and interleaving-dependent assertion violations. Previous work has only addressed these challenges in isolation, by either designing a new declarative language, a new data race detection tool or a new testing technique. We present P#, a language for high-reliability asynchronous programming co-designed with a static data race analysis and systematic concurrency testing infrastructure. We describe our experience using P# to write several distributed protocols and port an industrial-scale system internal to Microsoft, showing that the combined techniques, by leveraging the design of P#, are effective in finding bugs.

    References

    [1]
    T. Andrews, S. Qadeer, S. K. Rajamani, J. Rehof, and Y. Xie. Zing: A model checker for concurrent software. In Proceedings of the 16th International Conference on Computer Aided Verification, volume 3114 of Lecture Notes in Computer Science, pages 484–487. Springer, 2004.
    [2]
    Apple Inc. Grand Central Dispatch (GCD) reference, accessed November 2014. URL https://developer.apple.com/library/mac/ documentation/Performance/Reference/GCD_libdispatch_ Ref/index.html.
    [3]
    S. Blackshear, B. E. Chang, and M. Sridharan. Thresher: Precise refutations for heap reachability. In Proceedings of the 34th ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 275–286. ACM, 2013.
    [4]
    S. Burckhardt, P. Kothari, M. Musuvathi, and S. Nagarakatte. A randomized scheduler with probabilistic guarantees of finding bugs. In Proceedings of the 15th Edition of ASPLOS on Architectural Support for Programming Languages and Operating Systems, pages 167–178. ACM, 2010.
    [5]
    T. D. Chandra, R. Griesemer, and J. Redstone. Paxos made live: An engineering perspective. In Proceedings of the 26th Annual ACM Symposium on Principles of Distributed Computing, pages 398–407. ACM, 2007.
    [6]
    A. Desai, V. Gupta, E. K. Jackson, S. Qadeer, S. K. Rajamani, and D. Zufferey. P: Safe asynchronous event-driven programming. In Proceedings of the 34th ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 321–332. ACM, 2013.
    [7]
    A. Desai, P. Garg, and P. Madhusudan. Natural proofs for asynchronous programs using almost-synchronous reductions. In Proceedings of the 2014 ACM International Conference on Object Oriented Programming Systems Languages & Applications, pages 709––725. ACM, 2014.
    [8]
    A. Desai, S. Qadeer, and S. Seshia. Systematic testing of asynchronous reactive systems. Technical Report MSR-TR-2015-25, Microsoft Research, 2015.
    [9]
    M. Emmi, S. Qadeer, and Z. Rakamari´c. Delay-bounded scheduling. In Proceedings of the 38th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, pages 411–422. ACM, 2011.
    [10]
    S. German. Tutorial on verification of distributed cache memory protocols. In Formal Methods in Computer Aided Design, 2004.
    [11]
    P. Godefroid. Partial-Order Methods for the Verification of Concurrent Systems: An Approach to the State-Explosion Problem. Springer, 1996.
    [12]
    P. Godefroid. Model checking for programming languages using VeriSoft. In Proceedings of the 24th ACM Symposium on Principles of Programming Languages, pages 174–186. ACM, 1997.
    [13]
    J. N. Gray. Notes on Data Base Operating Systems. Springer, 1978.
    [14]
    O. Gruber and F. Boyer. Ownership-based isolation for concurrent actors on multi-core machines. In Proceedings of the 27th European Conference on Object-Oriented Programming, volume 7920 of Lecture Notes in Computer Science, pages 281–301. Springer, 2013.
    [15]
    P. Haller and M. Odersky. Capabilities for uniqueness and borrowing. In Proceedings of the 24th European Conference on Object-Oriented Programming, volume 6183 of Lecture Notes in Computer Science, pages 354–378. Springer, 2010.
    [16]
    L. Lamport. The part-time parliament. ACM Transactions on Computer Systems, 16(2):133–169, 1998.
    [17]
    S. Lauterburg, R. K. Karmani, D. Marinov, and G. Agha. Evaluating ordering heuristics for dynamic partial-order reduction techniques. In Proceedings of the 13th International Conference on Fundamental Approaches to Software Engineering, volume 6013 of Lecture Notes in Computer Science, pages 308–322. Springer, 2010.
    [18]
    D. Leijen, W. Schulte, and S. Burckhardt. The design of a task parallel library. In Proceedings of the 24th ACM SIGPLAN Conference on Object Oriented Programming Systems Languages and Applications, pages 227–242. ACM, 2009.
    [19]
    M. Musuvathi, S. Qadeer, T. Ball, G. Basler, P. A. Nainar, and I. Neamtiu. Finding and reproducing Heisenbugs in concurrent programs. In Proceedings of the 8th USENIX Conference on Operating Systems Design and Implementation, pages 267–280. USENIX Association, 2008.
    [20]
    S. Negara, R. K. Karmani, and G. Agha. Inferring ownership transfer for efficient message passing. In Proceedings of the 16th ACM Symposium on Principles and Practice of Parallel Programming, pages 81–90. ACM, 2011.
    [21]
    M. Odersky, L. Spoon, and B. Venners. Programming in Scala. Artima Inc, 2008.
    [22]
    D. Ongaro and J. Ousterhout. In search of an understandable consensus algorithm. In Proceedings of the 2014 USENIX Annual Technical Conference, pages 305–319. USENIX Association, 2014.
    [23]
    K. Sen and G. Agha. Automated systematic testing of open distributed programs. In Proceedings of the 9th International Conference on Fundamental Approaches to Software Engineering, volume 3922 of Lecture Notes in Computer Science, pages 339–356. Springer, 2006.
    [24]
    I. Stoica, R. Morris, D. Karger, M. F. Kaashoek, and H. Balakrishnan. Chord: A scalable peer-to-peer lookup service for internet applications. In Proceedings of the 2001 Conference on Applications, Technologies, Architectures, and Protocols for Computer Communications, pages 149–160. ACM, 2001.
    [25]
    P. Thomson, A. F. Donaldson, and A. Betts. Concurrency testing using schedule bounding: An empirical study. In Proceedings of the 19th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, pages 15–28. ACM, 2014.
    [26]
    R. van Renesse and F. B. Schneider. Chain replication for supporting high throughput and availability. In Proceedings of the 6th Symposium on Operating Systems Design and Implementation, pages 91–104. USENIX Association, 2004.
    [27]
    C. Varela and G. Agha. Programming dynamically reconfigurable open systems with SALSA. ACM SIGPLAN Notices, 36(12):20–34, 2001.
    [28]
    R. Virding, C. Wikström, and M. Williams. Concurrent Programming in Erlang. Prentice Hall International, 2nd edition, 1996.

    Cited By

    View all
    • (2023)Psym: Efficient Symbolic Exploration of Distributed SystemsProceedings of the ACM on Programming Languages10.1145/35912477:PLDI(660-685)Online publication date: 6-Jun-2023
    • (2023)Compiling Distributed System Models with PGoProceedings of the 28th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 210.1145/3575693.3575695(159-175)Online publication date: 27-Jan-2023
    • (2021)An Asynchronous Cooperative Signal Control Framework in Urban Road Network2021 6th International Conference on Transportation Information and Safety (ICTIS)10.1109/ICTIS54573.2021.9798689(1105-1111)Online publication date: 22-Oct-2021
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    PLDI '15: Proceedings of the 36th ACM SIGPLAN Conference on Programming Language Design and Implementation
    June 2015
    630 pages
    ISBN:9781450334686
    DOI:10.1145/2737924
    • cover image ACM SIGPLAN Notices
      ACM SIGPLAN Notices  Volume 50, Issue 6
      PLDI '15
      June 2015
      630 pages
      ISSN:0362-1340
      EISSN:1558-1160
      DOI:10.1145/2813885
      • Editor:
      • Andy Gill
      Issue’s Table of Contents
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Sponsors

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 03 June 2015

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. Asynchronous programming
    2. concurrency
    3. state machines
    4. static data race analysis
    5. systematic concurrency testing

    Qualifiers

    • Research-article

    Conference

    PLDI '15
    Sponsor:

    Acceptance Rates

    Overall Acceptance Rate 406 of 2,067 submissions, 20%

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)55
    • Downloads (Last 6 weeks)3

    Other Metrics

    Citations

    Cited By

    View all
    • (2023)Psym: Efficient Symbolic Exploration of Distributed SystemsProceedings of the ACM on Programming Languages10.1145/35912477:PLDI(660-685)Online publication date: 6-Jun-2023
    • (2023)Compiling Distributed System Models with PGoProceedings of the 28th ACM International Conference on Architectural Support for Programming Languages and Operating Systems, Volume 210.1145/3575693.3575695(159-175)Online publication date: 27-Jan-2023
    • (2021)An Asynchronous Cooperative Signal Control Framework in Urban Road Network2021 6th International Conference on Transportation Information and Safety (ICTIS)10.1109/ICTIS54573.2021.9798689(1105-1111)Online publication date: 22-Oct-2021
    • (2021)Nekara: Generalized Concurrency Testing2021 36th IEEE/ACM International Conference on Automated Software Engineering (ASE)10.1109/ASE51524.2021.9678838(679-691)Online publication date: Nov-2021
    • (2021)Data Flow Analysis of Asynchronous Systems using Infinite Abstract DomainsProgramming Languages and Systems10.1007/978-3-030-72019-3_2(30-58)Online publication date: 23-Mar-2021
    • (2020)Learning-based controlled concurrency testingProceedings of the ACM on Programming Languages10.1145/34282984:OOPSLA(1-31)Online publication date: 13-Nov-2020
    • (2020)Effective Concurrency Testing for Distributed SystemsProceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems10.1145/3373376.3378484(1141-1156)Online publication date: 9-Mar-2020
    • (2019)Toward New Unit-Testing Techniques for Shared-Memory Concurrent Programs2019 24th International Conference on Engineering of Complex Computer Systems (ICECCS)10.1109/ICECCS.2019.00025(164-169)Online publication date: Nov-2019
    • (2018)FCatchACM SIGPLAN Notices10.1145/3296957.317716153:2(419-431)Online publication date: 19-Mar-2018
    • (2018)FCatchProceedings of the Twenty-Third International Conference on Architectural Support for Programming Languages and Operating Systems10.1145/3173162.3177161(419-431)Online publication date: 19-Mar-2018
    • Show More Cited By

    View Options

    Get Access

    Login options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media