[go: up one dir, main page]
More Web Proxy on the site http://driver.im/ skip to main content
10.1145/3395363.3404368acmconferencesArticle/Chapter ViewAbstractPublication PagesisstaConference Proceedingsconference-collections
short-paper

FineLock: automatically refactoring coarse-grained locks into fine-grained locks

Published: 18 July 2020 Publication History

Abstract

Lock is a frequently-used synchronization mechanism to enforce exclusive access to a shared resource. However, lock-based concurrent programs are susceptible to lock contention, which leads to low performance and poor scalability. Furthermore, inappropriate granularity of a lock makes lock contention even worse. Compared to coarse-grained lock, fine-grained lock can mitigate lock contention but difficult to use. Converting coarse-grained lock into fine-grained lock manually is not only error-prone and tedious, but also requires a lot of expertise. In this paper, we propose to leverage program analysis techniques and pushdown automaton to automatically covert coarse-grained locks into fine-grained locks to reduce lock contention. We developed a prototype FineLock and evaluates it on 5 projects. The evaluation results demonstrate FineLock can refactor 1,546 locks in an average of 27.6 seconds, including converting 129 coarse-grained locks into fine-grained locks and 1,417 coarse-grained locks into read/write locks. By automatically providing potential refactoring recommendations, our tool saves a lot of efforts for developers.

References

[1]
Apache. 2019. Cassandra. https://cassandra.apache.org/
[2]
Bela Ban. 2019. JGroups. http://www.jgroups.org/
[3]
Standard Performance Evaluation Corporation. 2013. SPECjbb2005. https://www. spec.org/jbb2005/
[4]
Eclipse. 2020. Eclipse Java development tools. https://www.eclipse.org/jdt/
[5]
Hypersonic SQL Group. 2019. HSQLDB-100 % Java Database. http://hsqldb.org/
[6]
IBM. 2018. The t. j. watson libraries for analysis. http://wala.sourceforge.net/ wiki/index.php/Main_Pag
[7]
Kohsuke Kawaguchi. 2019. Jenkins. https://jenkins.io/
[8]
B. McCloskey, F. Zhou, D. Gay, and E. A. Brewer. 2006. Autolocker: synchronization inference for atomic sections. In Conference record of the 33rd ACM SIGPLAN-SIGACT symposium on Principles of programming languages. Association for Computing Machinery, 346-358.
[9]
Benjamin Muskalla. 2008. Concurrency-related refactorings for JDT. https: //wiki.eclipse.org/Concurrency-related_refactorings_for_JDT
[10]
M. Schäfer, M. Sridharan, J. Dolby, and F. Tip. 2011. Refactoring Java programs for flexible locking. In Proceedings of the 33rd International Conference on Software Engineering. ACM, 71-80.
[11]
Sixth and Red River Software. 2007. Locksmith. https://plugins.jetbrains.com/ plugin/1358-locksmith
[12]
Y. Zhang, S. Dong, X. Zhang, H. Liu, and D. Zhang. 2019. Automated Refactoring for Stampedlock. IEEE Access 7, 1 ( 2019 ), 104900-104911.

Cited By

View all
  • (2024)Automatically Injecting Robustness Statements into Distributed ApplicationsFuture Internet10.3390/fi1611041616:11(416)Online publication date: 10-Nov-2024
  • (2024)ExceRef: Automatically Refactoring for Exception HandlingProceedings of the 15th Asia-Pacific Symposium on Internetware10.1145/3671016.3674824(239-248)Online publication date: 24-Jul-2024
  • (2024)Mining Fine-grained Code Change Patterns Using Multiple Feature AnalysisInternational Journal of Software Engineering and Knowledge Engineering10.1142/S0218194024500505Online publication date: 20-Sep-2024
  • Show More Cited By

Index Terms

  1. FineLock: automatically refactoring coarse-grained locks into fine-grained locks

    Recommendations

    Comments

    Please enable JavaScript to view thecomments powered by Disqus.

    Information & Contributors

    Information

    Published In

    cover image ACM Conferences
    ISSTA 2020: Proceedings of the 29th ACM SIGSOFT International Symposium on Software Testing and Analysis
    July 2020
    591 pages
    ISBN:9781450380089
    DOI:10.1145/3395363
    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 the author(s) 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: 18 July 2020

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. Fine-grained lock
    2. Pushdown automaton
    3. Read-write lock
    4. Refactoring
    5. Static analysis

    Qualifiers

    • Short-paper

    Funding Sources

    • National Natural Science Foundation of China
    • National Natural Science Foundation of Hebei

    Conference

    ISSTA '20
    Sponsor:

    Acceptance Rates

    Overall Acceptance Rate 58 of 213 submissions, 27%

    Upcoming Conference

    ISSTA '25

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)19
    • Downloads (Last 6 weeks)2
    Reflects downloads up to 13 Dec 2024

    Other Metrics

    Citations

    Cited By

    View all
    • (2024)Automatically Injecting Robustness Statements into Distributed ApplicationsFuture Internet10.3390/fi1611041616:11(416)Online publication date: 10-Nov-2024
    • (2024)ExceRef: Automatically Refactoring for Exception HandlingProceedings of the 15th Asia-Pacific Symposium on Internetware10.1145/3671016.3674824(239-248)Online publication date: 24-Jul-2024
    • (2024)Mining Fine-grained Code Change Patterns Using Multiple Feature AnalysisInternational Journal of Software Engineering and Knowledge Engineering10.1142/S0218194024500505Online publication date: 20-Sep-2024
    • (2024)Consistency Checking for Refactoring from Coarse-Grained Locks to Fine-Grained LocksInternational Journal of Software Engineering and Knowledge Engineering10.1142/S021819402450014134:07(1063-1093)Online publication date: 5-Jun-2024
    • (2024) ReInstancer: An automatic refactoring approach for Instanceof pattern matching Journal of Software: Evolution and Process10.1002/smr.2661Online publication date: 12-Mar-2024
    • (2023)An Automatic Transformer from Sequential to Parallel Java CodeFuture Internet10.3390/fi1509030615:9(306)Online publication date: 8-Sep-2023
    • (2023)Performance Prediction for Lock-based Programs2023 IEEE 23rd International Conference on Software Quality, Reliability, and Security Companion (QRS-C)10.1109/QRS-C60940.2023.00028(437-446)Online publication date: 22-Oct-2023
    • (2022)ReInstancerProceedings of the ACM/IEEE 44th International Conference on Software Engineering: Companion Proceedings10.1145/3510454.3516868(183-187)Online publication date: 21-May-2022
    • (2022)ReInstancer: Automatically Refactoring for Instanceof Pattern Matching2022 IEEE/ACM 44th International Conference on Software Engineering: Companion Proceedings (ICSE-Companion)10.1109/ICSE-Companion55297.2022.9793818(183-187)Online publication date: May-2022
    • (2021)Consistency Validation Method for Java Fine-Grained Lock RefactoringIEEE Access10.1109/ACCESS.2021.31204149(149287-149301)Online publication date: 2021
    • Show More Cited By

    View Options

    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