Degrees of Separation: A Flexible Type System for Safe Concurrency
Yichen Xu, Aleksander Boruch-Gruszecki, Martin Odersky
摘要
Data races have long been a notorious problem in concurrent programming. They are hard to detect, and lead to non-deterministic behaviours. There has been a lot of interest in type systems that statically guarantee data race freedom. Significant progress has been made in this area, and these type systems are increasingly usable and practical. However, their adoption in mainstream programming languages is still limited, which is largely attributed to their strict alias prevention principles that obstruct the usage of existing programming patterns. This is a deterrent to the migration of existing code bases. To tackle this problem, we propose Capture Separation Calculus (System CSC), a calculus that models fork-join parallelism and statically prevents data races while being compatible with established programming patterns. It follows a control-as-you-need philosophy: by default, aliases are allowed, but they are tracked in the type system. When data races are a concern, the tracked aliases are controlled to prevent data-race-prone patterns. We study the formal properties of System CSC. Type soundness is proven via the standard progress and preservation theorems. Additionally, we formally verify the data race freedom property of System CSC by proving that the reduction of a well-typed program is confluent.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 10 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- A Lightweight Type-and-Effect System for Invalidation Safety: Tracking Permanent and Temporary Invalidation with Constraint-Based Subtype Inference 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- A Lightweight Type-and-Effect System for Invalidation Safety: Tracking Permanent and Temporary Invalidation with Constraint-Based Subtype Inference 引用了 Effects as capabilities: effect handlers and lightweight effect polymorphism
- A Lightweight Type-and-Effect System for Invalidation Safety: Tracking Permanent and Temporary Invalidation with Constraint-Based Subtype Inference 引用了 Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs
- What's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data Structures 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- What's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data Structures 引用了 Effects as capabilities: effect handlers and lightweight effect polymorphism
- What's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data Structures 引用了 Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs
- Reachability types: tracking aliasing and separation in higher-order functional programs 引用了 Effects as capabilities: effect handlers and lightweight effect polymorphism
- Complete the Cycle: Reachability Types with Expressive Cyclic References 引用了 A flexible type system for fearless concurrency
- Complete the Cycle: Reachability Types with Expressive Cyclic References 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- Complete the Cycle: Reachability Types with Expressive Cyclic References 引用了 Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types 引用了 Complete the Cycle: Reachability Types with Expressive Cyclic References
- Complete the Cycle: Reachability Types with Expressive Cyclic References 引用了 Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs
- Data Race Freedom à la Mode 引用了 A flexible type system for fearless concurrency
- Data Race Freedom à la Mode 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- Data Race Freedom à la Mode 引用了 Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types 引用了 A Lightweight Type-and-Effect System for Invalidation Safety: Tracking Permanent and Temporary Invalidation with Constraint-Based Subtype Inference
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types 引用了 What's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data Structures
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability Types 引用了 Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs
- Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs 引用了 Reachability types: tracking aliasing and separation in higher-order functional programs
- Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic Programs 引用了 Effects as capabilities: effect handlers and lightweight effect polymorphism
引用它的顶会 Paper10
- Data Race Freedom à la ModeAïna Linn Georges, Benjamin Peters, Laila Elbeheiry, Leo White 等POPL 2025 · 6 次引用
- A Lightweight Type-and-Effect System for Invalidation Safety: Tracking Permanent and Temporary Invalidation with Constraint-Based Subtype InferenceCunyuan Gao, Lionel ParreauxOOPSLA 2025 · 4 次引用
- What's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data StructuresYichen Xu, Oliver Bracevac, Cao Nguyen Pham, Martin OderskyOOPSLA 2025 · 4 次引用
- Complete the Cycle: Reachability Types with Expressive Cyclic ReferencesHaotian Deng, Siyuan He, Songlin Jia, Yuyan Bao 等OOPSLA 2025 · 3 次引用
- Escape with Your Self: Sound and Expressive Bidirectional Typing with Avoidance for Reachability TypesSonglin Jia, Guannan Wei, Siyuan He, Yuyan Bao 等PLDI 2026 · 1 次引用
它引用的 Paper4
- Effects as capabilities: effect handlers and lightweight effect polymorphismJonathan Immanuel Brachthäuser, Philipp Schuster, Klaus OstermannOOPSLA 2020 · 62 次引用
- Reachability types: tracking aliasing and separation in higher-order functional programsYuyan Bao, Guannan Wei, Oliver Bracevac, Yuxuan Jiang 等OOPSLA 2021 · 19 次引用
- A flexible type system for fearless concurrencyMae Milano, Joshua Turcotti, Andrew C. MyersPLDI 2022 · 14 次引用
- Polymorphic Reachability Types: Tracking Freshness, Aliasing, and Separation in Higher-Order Generic ProgramsGuannan Wei, Oliver Bracevac, Songlin Jia, Yuyan Bao 等POPL 2024 · 12 次引用
相关 Paper
- Accurate Static Data Race Detection for CEmerson Sales, Omar Inverso, Emilio TuostoFM 2024 · 1 次引用
- Law and Order for Typestate with BorrowingHannes Saffrich, Yuki Nishida, Peter ThiemannOOPSLA 2024 · 1 次引用
- Model Checking Race-Freedom When "Sequential Consistency for Data-Race-Free Programs" is GuaranteedWenhao Wu, Jan Hückelheim, Paul D. Hovland, Ziqing Luo 等CAV 2023 · 1 次引用
- Classifying CapabilitiesCao Nguyen Pham, Oliver Bračevac, Yichen Xu, Yaoyu Zhao 等OOPSLA 2026
- From Linearity to BorrowingAndrew Wagner, Olek Gierczak, Brianna Marshall, John M. Li 等OOPSLA 2025 · 1 次引用
