一句话:提出基于引用能力的属主类型系统,强制 Verona 中区域隔离,支持对象跨区域与线程移动,且数据访问无需原子操作。
Verona 是一种并发面向对象语言,它将程序中的所有对象组织成由相互隔离的区域构成的森林,每个区域在本地管理内存——程序员可通过调整对象到区域的划分以及设定各区域的内存管理策略来控制内存使用。线程只能在其“可变窗口”对应的活动区域内分配与释放对象,因而内存管理开销被局部化、可预测。本文提出一种基于引用能力的属主类型系统,用于强制区域隔离并控制区域内部及区域之间的别名,同时支持对象在区域与线程之间移动。数据访问无需昂贵的原子操作,且始终线程安全。
Verona is a concurrent object-oriented programming language that organises all the objects in a program into a forest of isolated regions. Memory is managed locally for each region, so programmers can control a program's memory use by adjusting objects' partition into regions, and by setting each region's memory management strategy. A thread can only mutate (allocate, deallocate) objects within one active region---its "window of mutability". Memory management costs are localised to the active region, ensuring overheads can be predicted and controlled. Moving the mutability window between regions is explicit, so code can be executed wherever it is required, yet programs remain in control of memory use. An ownership type system based on reference capabilities enforces region isolation, controlling aliasing within and between regions, yet supporting objects moving between regions and threads. Data accesses never need expensive atomic operations, and are always thread-safe.
@article{paperbot1882,
title = {Reference Capabilities for Flexible Memory Management},
author = {Ellen Arvidsson and Elias Castegren and Sylvan Clebsch and Sophia Drossopoulou and James Noble and Matthew J. Parkinson and Tobias Wrigstad},
journal = {Proceedings of the ACM on Programming Languages},
volume = {7},
number = {OOPSLA2},
year = {2023},
doi = {10.1145/3622846}
}