End-to-End Sequential Consistency EtE-SC
An approach to providing end-to-end sequential consistency for a language, enforced jointly by an SC-preserving variant of the LLVM compiler and modified x86 hardware. To curb the overhead it enforces SC only for accesses to shared mutable variables, classifying memory regions as thread-local, shared-immutable, or shared-mutable via a combination of static compiler analysis and hardware-assisted dynamic analysis. Reported overhead is 6.2% on average (17% maximum) versus stock LLVM and x86. Like the other SC-preserving designs it admits exactly the SC behaviours.
Properties
Property vector survey-sourced — from Tables 1–2 of the Moiseenko et al. survey, except cells that cite a specific source.
- Compilation optimal mapping to
- no x86
- no POWER
- no Armv7
- no Armv8
- Reordering sound
- no Store→Load
- no Store→Store
- no Load→Load
- no Load→Store
- Elimination sound
- yes Store/Load
- yes Store/Store
- yes Load/Load
- yes Load/Store
- Other local transformations
- yes Irrelevant load elim.
- yes Speculative load intro.
- yes Roach motel
- yes Inverse roach motel Poetzl & Kroening 2015
- yes Strengthening
- yes Trace preserving
- no Common subexpr. elim.
- Global transformations
- yes Register promotion
- yes Thread inlining
- Reasoning guarantees
- yes External DRF
- yes Coherence
- yes No undefined behaviour
- yes In-order execution
- yes No out-of-thin-air
Ordering relationships
- Equivalent to
- Sequential Consistency (SC) — EtE-SC restores end-to-end sequential consistency via an SC-preserving LLVM compiler and modified x86 hardware; it admits exactly the SC outcomes, differing from SC only in enforcement mechanism and performance, not in allowed behaviours.
References
- Daniel Marino, Abhayendra Singh, Todd Millstein, Madanlal Musuvathi, Satish Narayanasamy. A Case for an SC-Preserving Compiler. PLDI 2011, 2011. doi:10.1145/1993316.1993522
- Abhayendra Singh, Satish Narayanasamy, Daniel Marino, Todd Millstein, Madanlal Musuvathi. End-to-End Sequential Consistency. ISCA 2012, 2012. doi:10.1109/ISCA.2012.6237045
- Evgenii Moiseenko, Anton Podkopaev, Dmitrii Koznov. A Survey of Programming Language Memory Models. Programming and Computer Software 47(6), pp. 439–456, 2021. doi:10.1134/S0361768821060050
- Daniel Poetzl, Daniel Kroening. Formalizing and Checking Thread Refinement for Data-Race-Free Execution Models. arXiv:1510.07171, 2015. arxiv.org/abs/1510.07171