This study by Maurice Herlihy of Brown University revisits a landmark 1993 paper by Damon, discussing the impact and evolution of Transactional Memory (TM) over the years. It delves into the benefits, challenges, and efficiency of various language supports like Clojure, Scala, Haskell, and more in the context of TM. The research explores the necessity for better lock-free data structures, scalability, power efficiency, and software engineering practices. It also examines the technical aspects like Hardware TM (HTM), Software TM (STM), Lock Elision techniques, and their implications on transactional and non-transactional threads synchronization. The study further evaluates the strengths and weaknesses of HTM and the need for STM due to their composition challenges within practical TM implementations.
01 / 81Sweet Sixteen: How well is Transactional Memory Aging?
1 / 17
Télécharger la présentation
Sweet Sixteen: How well is Transactional Memory Aging?
Une image / un lien ci-dessous est fourni (tel quel) pour télécharger la présentation
Politique de téléchargement : le contenu du site vous est fourni TEL QUEL pour votre information et votre usage personnel ; il ne peut être vendu, concédé sous licence ni partagé sur d’autres sites sans l’accord de son auteur.Le contenu vous est fourni TEL QUEL, pour votre information et votre usage personnel uniquement.Téléchargez la présentation en cliquant sur ce lien.Lors du téléchargement, si vous ne parvenez pas à télécharger une présentation, l’éditeur a peut-être supprimé le fichier de son serveur.Pendant le téléchargement, si vous ne parvenez pas à obtenir une présentation, le fichier a peut-être été supprimé par l’éditeur.
HTM Strengths & Weaknesses • Ideal for lock-free data structures • Practical proposals have limits on • Transaction size and length • Bounded HW resources • Guarantees vs best-effort Damon June 2009
HTM Strengths & Weaknesses • Ideal for lock-free data structures • Practical proposals have limits on • Transaction size and length • Bounded HW resources • Guarantees vs best-effort • On fail • Diagnostics essential • Retry in software? Damon June 2009
Composition Locks don’t compose, transactions do. Composition necessary for Software Engineering. But practical HTM doesn’treallysupport composition! Why we need STM Damon June 2009
Outline • What and why • Hardware TM • Software TM • Lock Elision • Conversion • User studies • Energy atomic { node.next = succ; node.prev = pred; succ.pred = node; pred.next = node; } Damon June 2009
STM • Code appears to execute atomically • Typically executed speculatively atomic { node.next = succ; node.prev = pred; succ.pred = node; pred.next = node; } Damon June 2009
Some I/O revocable Provide transaction-safe libraries Undoable file system/DB calls Some not Dispensing cash Firing missile I/O & System Calls? Damon June 2009
Transactions act as if they acquire SGL Good: Intuitively appealing Bad: What about aborted transactions? Conditional synchronization? Single Global Lock Semantics? Damon June 2009
Outline • What and why • Hardware TM • Software TM • Lock Elision • Conversion • User studies • Energy lock(x) { node.next = succ; node.prev = pred; succ.pred = node; pred.next = node; } Damon June 2009
Lock Elision Transparently replace critical sections with transactions Damon June 2009
Lock Elision • Execute critical section speculatively Synchronize on data, not locks lock(x) { node.next = succ; node.prev = pred; succ.pred = node; pred.next = node; } Fall back to locking on repeated FAIL Damon June 2009
Benefits • Transparent • No need to retrain programmers Damon June 2009
Benefits • Transparent • No need to retrain programmers • Works on much legacy code • Not all, see Azul report below Damon June 2009
Benefits • Transparent • No need to retrain programmers • Works on much legacy code • Not all • Ideal for managed run-times Damon June 2009
Applied Lock Elision Lock Elision for contended Java synchronized blocks Good on some, modest on many, bad on few Gratuitous conflicts limit gains Rewriting helps, but tedious Damon June 2009
Connexion au compte
Connectez-vous pour publier votre contenu sur SlideServe.