ComputingComputer EngineeringComputer ScienceComputer ArchitectureOperating SystemsParallel ComputingConcurrency AnalysisConcurrency ControlConcurrent ProgrammingParallel Programming ModelsRace Condition VulnerabilitiesSynchronization PrimitivesLockingLocking MechanismsMulti-core ComputingParallel ProgrammingRace ConditionsTransactional MemoryTransactional Memory SemanticsWeb Server Architecture
The movement to multi-core processors increases the need for simpler, more robust parallel programming models. Atomic sections have been widely recognized for their ease of use. They are simpler and safer to use than manual locking and they increase modularity. But existing proposals have several practical problems, including high overhead and poor interaction with I/O. We present pessimistic atomic sections, a fresh approach that retains many of the advantages of optimistic atomic sections as seen in "transactional memory" without sacrificing performance or compatibility. Pessimistic atomic sections employ the locking mechanisms familiar to programmers while relieving them of most burdens of lock-based programming, including deadlocks. Significantly, pessimistic atomic sections separate correctness from performance: they allow programmers to extract more parallelism via finer-grained locking without fear of introducing bugs. We believe this property is crucial for exploiting multi-core processor designs.We describe a tool, Autolocker, that automatically converts pessimistic atomic sections into standard lock-based code. Autolocker relies extensively on program analysis to determine a correct locking policy free of deadlocks and race conditions. We evaluate the expressiveness of Autolocker by modifying a 50,000 line high-performance web server to use atomic sections while retaining the original locking policy. We analyze Autolocker's performance using microbenchmarks, where Autolocker outperforms software transactional memory by more than a factor of 3.
37
Maurice Herlihy, J. Eliot B. Moss · 1993 · 2.2K citations
Stefan Savage, Michael T. Burrows, Greg Nelson et al. · ACM Transactions on Computer Systems · 1997 · 1.6K citations · Full text
Software transactional memory for dynamic-sized data structures
Maurice Herlihy, Victor Luchangco, Mark Moir et al. · 2003 · 999 citations
Composable memory transactions
Tim Harris, Simon Marlow, Simon Peyton-Jones et al. · 2005 · 716 citations