Thesis (Ph. D.)--University of Rochester. Department of Computer Science, 2019.
The Haskell programming language is an active laboratory for cutting edge ideas. Early in the evolution of transactional memory (TM), Haskell included language support and quickly grew a community of TM users. Since TM's inclusion in Haskell, a flurry of research has brought significant developments in TM in non-Haskell contexts including improved understanding of TM semantics, higher-performance implementations, and support for TM in commodity hardware. The community of Haskell TM users has continued to grow, largely due to composition and blocking features that are included in Haskell's TM but are typically missing from TM implementations in other languages. In this thesis we connect Haskell with new developments from the TM
research community while preserving Haskell's rich TM features. We explore the challenges of integrating new ideas, including Transactional Locking II and hardware TM (HTM) into a pure functional programming language,
and evaluate the performance of our developments. Achieving good cache performance, particularly avoiding speculative overflow, is critical to realizing benefits from HTM in its current form. To this end we implement a TM
that removes indirection and allows for multiple transactional fields in a single heap object. To enable access to these features, we extend the Haskell language, implementing support for mutable constructor fields. Together
these changes yield an implementation with significantly better performance than the original TM.
We also explore the potential of using Haskell's advanced type system to decrease the cost of unused features. We argue that this can be achieved while still maintaining the existing API. More static information can be used
both by the compiler to improve code and by users to better understand the performance characteristics of their code.