{"title":"Jthread, a deadlock-free mutex library","authors":"J. Grande, G. Boudol, M. Serrano","doi":"10.1145/2790449.2790523","DOIUrl":null,"url":null,"abstract":"We design a mutex library for Hop -- a dialect of Scheme which supports preemptive multithreading and shared memory -- that mixes deadlock prevention and deadlock avoidance to provide an easy to use, expressive, and safe locking function. This requires an operation to acquire several mutexes simultaneously, for which we provide a starvation-free algorithm. Choosing a formal definition of starvation-freedom leads us to identify the concept of asymptotic deadlock. Preliminary observations seem to show that our library has negligible impact on the performance of real-life applications. Our work could be applied to other languages such as Java.","PeriodicalId":445788,"journal":{"name":"Proceedings of the 17th International Symposium on Principles and Practice of Declarative Programming","volume":"17 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2015-07-14","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"2","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 17th International Symposium on Principles and Practice of Declarative Programming","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2790449.2790523","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 2
Abstract
We design a mutex library for Hop -- a dialect of Scheme which supports preemptive multithreading and shared memory -- that mixes deadlock prevention and deadlock avoidance to provide an easy to use, expressive, and safe locking function. This requires an operation to acquire several mutexes simultaneously, for which we provide a starvation-free algorithm. Choosing a formal definition of starvation-freedom leads us to identify the concept of asymptotic deadlock. Preliminary observations seem to show that our library has negligible impact on the performance of real-life applications. Our work could be applied to other languages such as Java.