Initializing Global Objects: Time and Order
Fengyun Liu, Ondrej Lhoták, David Hua, Enze Xing
摘要
Object-oriented programming has been bothered by an awkward feature for a long time: static members. Static members not only compromise the conceptual integrity of object-oriented programming, but also give rise to subtle initialization errors, such as reading non-initialized fields and deadlocks.
The Scala programming language eliminated static members from the language, replacing them with global objects that present a unified object-oriented programming model. However, the problem of global object initialization remains open, and programmers still suffer from initialization errors.
We propose partial ordering and initialization-time irrelevance as two fundamental principles for initializing global objects. Based on these principles, we put forward an effective static analysis to ensure safe initialization of global objects, which eliminates initialization errors at compile time. The analysis also enables static scheduling of global object initialization to avoid runtime overhead. The analysis is modular at the granularity of objects and it avoids whole-program analysis. To make the analysis explainable and tunable, we introduce the concept of regions to make context-sensitivity understandable and customizable by programmers.
CCS Concepts: • Software and its engineering → Object oriented languages; Classes and objects.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper1
问问它们各自怎么用它它引用的顶会 Paper2
- A type-and-effect system for object initializationFengyun Liu, Ondrej Lhoták, Aggelos Biboudis, Paolo G. Giarrusso 等OOPSLA 2020 · 被引用 8 次
- A conceptual framework for safe object initialization: a principled and mechanized soundness proof of the Celsius modelClement Blaudeau, Fengyun LiuOOPSLA 2022 · 被引用 2 次
相关 Paper
- ιDOT: a DOT calculus with object initializationIfaz Kabir, Yufeng Li, Ondrej LhotákOOPSLA 2020 · 被引用 3 次
- A practical mode system for recursive definitionsAlban Reynaud, Gabriel Scherer, Jeremy YallopPOPL 2021 · 被引用 2 次
- Modular Type Safety for Traits with Extensible Variants and Deep Pattern MatchingAndong Fan, Lionel Parreaux, Ningning XieOOPSLA 2026
- CiFi: Versatile Analysis of Class and Field ImmutabilityTobias Roth, Dominik Helm, Michael Reif, Mira MeziniASE 2021 · 被引用 7 次
- Optimistic Stack Allocation and Dynamic Heapification for Managed RuntimesAditya Anand, Solai Adithya, Swapnil Rustagi, Priyam Seth 等PLDI 2024 · 被引用 4 次
