Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/2338967.2336808acmconferencesArticle/Chapter ViewAbstractPublication PagesisstaConference Proceedingsconference-collections
Article

On-the-fly detection of data races in OpenMP programs

Published: 16 July 2012 Publication History
  • Get Citation Alerts
  • Abstract

    OpenMP provides a portable way to achieve high performance and simple compiler directives to transform a sequential program into parallel program. It is important to detect data races in OpenMP programs, because they may lead to unpredictable results from an execution of the programs. To detect data races that occur during an execution of OpenMP programs, the representative on-the-fly technique, Helgrind+, mainly focuses on reducing false positives. Unfortunately, this technique is still imprecise and inefficient, when applied to large OpenMP programs which use a structured fork-join parallelism with a large number of threads. This paper presents a novel approach which efficiently detects apparent data races without false positives in large OpenMP programs. This approach combines an efficient thread labeling to maintain the logical concurrency of thread segments with a precise detection protocol to analyze conflicting accesses to every shared memory location. We implemented this approach on top of the Pin binary instrumentation framework and compared it with Helgrind+. Empirical results using OpenMP benchmarks show that our technique detects apparent data races without false positives contrarily to Helgrind+, while reducing the average runtime overhead to 19% of Helgrind+ with a similar amount of space overhead.

    References

    [1]
    M. Bach, M. Charney, R. Cohn, E. Demikhovsky, T. Devor, K. Hazelwood, A. Jaleel, C.-K. Luk, G. Lyons, H. Patil, and A. Tal. Analyzing parallel programs with pin. Computer, 43(3):34-41, March 2010.
    [2]
    U. Banerjee, B. Bliss, Z. Ma, and P. Petersen. A theory of data race detection. In Proceedings of the 2006 workshop on Parallel and distributed systems: testing and debugging, PADTAD'06, pages 69-78, New York, USA, 2006. ACM.
    [3]
    M. A. Bender, J. T. Fineman, S. Gilbert, and C. E. Leiserson. On-the-fly maintenance of series-parallel relationships in fork-join multithreaded programs. In Proceedings of the 16th annual ACM symposium on Parallelism in algorithms and architectures, SPAA'04, pages 133-144, New York, USA, 2004. ACM.
    [4]
    C. Bienia and K. Li. Parsec 2.0: A new benchmark suite for chip-multiprocessors. In Proceedings of the 5th Annual Workshop on Modeling, Benchmarking and Simulation, June 2009.
    [5]
    H. M. Bücker, A. Rasch, and A. Wolf. A class of openmp applications involving nested parallelism. In Proc. of the 2004 ACM symp. on Applied comput., SAC'04, pages 220-224, New York, USA, 2004. ACM.
    [6]
    L. Dagum and R. Menon. Openmp: an industry standard api for shared-memory programming. Computational Science Engineering, IEEE, 5(1):46-55, Jan.-Mar. 1998.
    [7]
    A. Dinning and E. Schonberg. Detecting access anomalies in programs with critical sections. In Proceedings of the 1991 ACM/ONR workshop on Parallel and distributed debugging, PADD'91, pages 85-96, New York, NY, USA, 1991. ACM.
    [8]
    A. J. Dorta, C. Rodriguez, F. d. Sande, and A. Gonzalez-Escribano. The openmp source code repository. In Proceedings of the 13th Euromicro Conference on Parallel, Distributed and Network-Based Processing, pages 244-250, Washington, DC, USA, 2005. IEEE Computer Society.
    [9]
    O. Ha and Y. Jun. Efficient thread labeling for on-the-fly race detection of programs with nested parallelism. In Software Engineering, Business Continuity, and Education, volume 257 of Communications in Computer and Information Science, pages 424-436. Springer Berlin Heidelberg, 2011.
    [10]
    J. J. Harrow. Runtime checking of multithreaded applications with visual threads. In Proceedings of the 7th International SPIN Workshop on SPIN Model Checking and Software Verification, pages 331-342, London, UK, 2000. Springer-Verlag.
    [11]
    A. Jannesari and W. F. Tichy. On-the-fly race detection in multi-threaded programs. In Proceedings of the 6th workshop on Parallel and distributed systems: testing, analysis, and debugging, PADTAD'08, pages 6:1-6:10, New York, USA, 2008. ACM.
    [12]
    A. Jannesari, B. Kaibin, V. Pankratius, and W. F. Tichy. Helgrind+: An efficient dynamic race detector. In Proceedings of the 2009 IEEE International Symposium on Parallel & Distributed Processing, IPDPS'09, pages 1-13, Washington, DC, USA, 2009. IEEE Computer Society.
    [13]
    A. Jannesari and W. Tichy. Identifying ad-hoc synchronization for enhanced race detection. In Parallel Distributed Processing (IPDPS), 2010 IEEE International Symposium on, pages 1-10, April 2010.
    [14]
    L. Lamport. Time, clocks, and the ordering of events in a distributed system. Commun. ACM, 21:558-565, July 1978.
    [15]
    J. Mellor-Crummey. On-the-fly detection of data races for programs with nested fork-join parallelism. In Proceedings of the 1991 ACM/IEEE conference on Supercomputing, Supercomputing'91, pages 24-33, New York, USA, 1991. ACM.
    [16]
    N. Nethercote and J. Seward. How to shadow every byte of memory used by a program. In Proceedings of the 3rd international conference on Virtual execution environments, VEE'07, pages 65-74, New York, NY, USA, 2007. ACM.
    [17]
    R. H. B. Netzer and B. P. Miller. What are race conditions?: Some issues and formalizations. ACM Lett. Program. Lang. Syst., 1:74-88, March 1992.
    [18]
    H. Nishiyama. Detecting data races using dynamic escape analysis based on read barrier. In Proceedings of the 3rd conference on Virtual Machine Research And Technology Symposium - Volume 3, pages 10-10, Berkeley, CA, USA, 2004. USENIX Association.
    [19]
    R. O'Callahan and J.-D. Choi. Hybrid dynamic data race detection. In Proceedings of the ninth ACM SIGPLAN symposium on Principles and practice of parallel programming, PPoPP'03, pages 167-178, New York, USA, 2003. ACM.
    [20]
    The openmp api specification for parallel programming. In http://www.openmp.org, 2008.
    [21]
    E. Pozniansky and A. Schuster. Efficient on-the-fly data race detection in multithreaded c++ programs. In Proceedings of the ninth ACM SIGPLAN symposium on Principles and practice of parallel programming, PPoPP'03, pages 179-190, New York, NY, USA, 2003. ACM.
    [22]
    R. Raman, J. Zhao, V. Sarkar, M. Vechev, and E. Yahav. Efficient data race detection for async-finish parallelism. In Proceedings of the First international conference on Runtime verification, RV'10, pages 368-383, Berlin, Heidelberg, 2010. Springer-Verlag.
    [23]
    M. Ronsse and K. De Bosschere. Recplay: a fully integrated practical record/replay system. ACM Trans. Comput. Syst., 17:133-152, May 1999.
    [24]
    S. Savage, M. Burrows, G. Nelson, P. Sobalvarro, and T. Anderson. Eraser: a dynamic data race detector for multithreaded programs. ACM Trans. Comput. Syst., 15:391-411, November 1997.
    [25]
    Y. Yu, T. Rodeheffer, and W. Chen. Racetrack: efficient detection of data race conditions via adaptive tracking. In Proceedings of the twentieth ACM symposium on Operating systems principles, SOSP'05, pages 221-234, New York, NY, USA, 2005. ACM.

    Cited By

    View all
    • (2023)A Survey on Parallelism and DeterminismACM Computing Surveys10.1145/356452955:10(1-28)Online publication date: 2-Feb-2023
    • (2023)Model Checking Race-Freedom When “Sequential Consistency for Data-Race-Free Programs” is GuaranteedComputer Aided Verification10.1007/978-3-031-37703-7_13(265-287)Online publication date: 17-Jul-2023
    • (2022)On-the-Fly Repairing of Atomicity Violations in ARINC 653 SoftwareApplied Sciences10.3390/app1204201412:4(2014)Online publication date: 15-Feb-2022
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    PADTAD 2012: Proceedings of the 2012 Workshop on Parallel and Distributed Systems: Testing, Analysis, and Debugging
    July 2012
    46 pages
    ISBN:9781450314565
    DOI:10.1145/2338967
    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

    In-Cooperation

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 16 July 2012

    Permissions

    Request permissions for this article.

    Check for updates

    Qualifiers

    • Article

    Conference

    ISSTA '12
    Sponsor:

    Upcoming Conference

    ISSTA '24

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)4
    • Downloads (Last 6 weeks)0
    Reflects downloads up to 11 Aug 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2023)A Survey on Parallelism and DeterminismACM Computing Surveys10.1145/356452955:10(1-28)Online publication date: 2-Feb-2023
    • (2023)Model Checking Race-Freedom When “Sequential Consistency for Data-Race-Free Programs” is GuaranteedComputer Aided Verification10.1007/978-3-031-37703-7_13(265-287)Online publication date: 17-Jul-2023
    • (2022)On-the-Fly Repairing of Atomicity Violations in ARINC 653 SoftwareApplied Sciences10.3390/app1204201412:4(2014)Online publication date: 15-Feb-2022
    • (2022)Just-in-Time Compilation and Link-Time Optimization for OpenMP Target OffloadingOpenMP in a Modern World: From Multi-device Support to Meta Programming10.1007/978-3-031-15922-0_10(145-158)Online publication date: 20-Sep-2022
    • (2020)Towards a Qualifiable OpenMP Framework for Embedded Systems2020 Design, Automation & Test in Europe Conference & Exhibition (DATE)10.23919/DATE48585.2020.9116230(903-908)Online publication date: Mar-2020
    • (2020)Enhancing DataRaceBench for Evaluating Data Race Detection Tools2020 IEEE/ACM 4th International Workshop on Software Correctness for HPC Applications (Correctness)10.1109/Correctness51934.2020.00008(20-30)Online publication date: Nov-2020
    • (2019)Hunting Superfluous Locks with Model CheckingFrom Software Engineering to Formal Methods and Tools, and Back10.1007/978-3-030-30985-5_24(416-432)Online publication date: 9-Oct-2019
    • (2018)Dynamic data race detection for OpenMP programsProceedings of the International Conference for High Performance Computing, Networking, Storage, and Analysis10.5555/3291656.3291738(1-12)Online publication date: 11-Nov-2018
    • (2018)Dynamic data race detection for OpenMP programsProceedings of the International Conference for High Performance Computing, Networking, Storage, and Analysis10.1109/SC.2018.00064(1-12)Online publication date: 11-Nov-2018
    • (2017)Software Analysis Techniques for Detecting Data RaceIEICE Transactions on Information and Systems10.1587/transinf.2017EDR0004E100.D:11(2674-2682)Online publication date: 2017
    • 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