Ctrie
A concurrent hash-trie or Ctrie is a concurrent thread-safe lock-free implementation of a hash array mapped trie. It is used to implement the concurrent map abstraction. It has particularly scalable concurrent insert and remove operations and is memory-efficient. It is the first known concurrent data-structure that supports O(1), atomic, lock-free snapshots.
A concurrent hash-trie or Ctrie is a concurrent thread-safe lock-free implementation of a hash array mapped trie. It is used to implement the concurrent map abstraction. It has particularly scalable concurrent insert and remove operations and is memory-efficient. It is the first known concurrent data-structure that supports O(1), atomic, lock-free snapshots. bit = bmp & (1 > level) & 0x1F)) pos = bitcount((bit - 1) & bmp) Note that the operations treat only the I-nodes as mutable nodes - all other nodes are never changed after being created and added to the Ctrie. Below is an illustration of the pseudocode of the insert operation: def insert(k, v) r = READ(root) if iinsert(r, k, v, 0, null) = RESTART insert(k, v) def iinsert(i, k, v, lev, parent) cn = READ(i.main) flag, pos = flagpos(k.hc, lev, cn.bmp) if cn.bmp & flag = 0 { ncn = cn.inserted(pos, flag, SNode(k, v)) if CAS(i.main, cn, ncn) return OK else return RESTART } cn.array(pos) match { case sin: INode => { return iinsert(sin, k, v, lev + W, i) case sn: SNode => if sn.k ≠ k { nsn = SNode(k, v) nin = INode(CNode(sn, nsn, lev + W)) ncn = cn.updated(pos, nin) if CAS(i.main, cn, ncn) return OK else return RESTART } else { ncn = cn.updated(pos, SNode(k, v)) if CAS(i.main, cn, ncn) return OK else return RESTART } } The inserted and updated methods on nodes return new versions of the C-node with a value inserted or updated at the specified position, respectively. Note that the insert operation above is tail-recursive, so it can be rewritten as a while loop. Other operations are described in more detail in the original paper on Ctries. The data-structure has been proven to be correct - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. The lookup operation can be modified to guarantee wait-freedom.
References
- Cache-Aware Lock-Free Concurrent Hash Tries . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "Cache-Aware Lock-Free Concurrent Hash Tries ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "Cache-Aware Lock-Free Concurrent Hash Tries ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). Cache-Aware Lock-Free Concurrent Hash Tries . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- ctrie: Non-blocking concurrent hashmap for Haskell . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "ctrie: Non-blocking concurrent hashmap for Haskell ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "ctrie: Non-blocking concurrent hashmap for Haskell ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). ctrie: Non-blocking concurrent hashmap for Haskell . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- triemap: Java port of . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "triemap: Java port of ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "triemap: Java port of ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). triemap: Java port of . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- java-concurrent-hash-trie-map: Java port of a concurrent trie hash map implemen . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "java-concurrent-hash-trie-map: Java port of a concurrent trie hash map implemen ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "java-concurrent-hash-trie-map: Java port of a concurrent trie hash map implemen ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). java-concurrent-hash-trie-map: Java port of a concurrent trie hash map implemen . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage models . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage models ." cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage mod. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage models ." cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage mod. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage mod. (2025). cl-ctrie: lock-free, concurrent, key/value index with efficient memory-mapped persistence and fast transient storage models . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- A Lock-Free Hash Trie Design for Concurrent Tabled Logic Programs . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "A Lock-Free Hash Trie Design for Concurrent Tabled Logic Programs ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "A Lock-Free Hash Trie Design for Concurrent Tabled Logic Programs ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). A Lock-Free Hash Trie Design for Concurrent Tabled Logic Programs . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- ctrie: Documentation . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "ctrie: Documentation ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "ctrie: Documentation ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). ctrie: Documentation . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- uses hazard pointers in its implementation to achieve lock-free synchronization. * Both a managed and an unmanaged C++ version of Ctrie was implemented [https://github.com/mthom/managed-ctrie Managed . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "uses hazard pointers in its implementation to achieve lock-free synchronization. * Both a managed and an unmanaged C++ version of Ctrie was implemented [https://github.com/mthom/managed-ctrie Managed ." uses hazard pointers in its implementation to achieve lock-free synchronization. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "uses hazard pointers in its implementation to achieve lock-free synchronization. * Both a managed and an unmanaged C++ version of Ctrie was implemented [https://github.com/mthom/managed-ctrie Managed ." uses hazard pointers in its implementation to achieve lock-free synchronization. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA uses hazard pointers in its implementation to achieve lock-free synchronization. (2025). uses hazard pointers in its implementation to achieve lock-free synchronization. * Both a managed and an unmanaged C++ version of Ctrie was implemented [https://github.com/mthom/managed-ctrie Managed . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- Concurrent Tries with Efficient Non-Blocking Snapshots . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "Concurrent Tries with Efficient Non-Blocking Snapshots ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "Concurrent Tries with Efficient Non-Blocking Snapshots ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). Concurrent Tries with Efficient Non-Blocking Snapshots . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- Lock-Free Resizeable Concurrent Tries . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "Lock-Free Resizeable Concurrent Tries ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "Lock-Free Resizeable Concurrent Tries ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). Lock-Free Resizeable Concurrent Tries . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- Ctrie - A Lock-Free Concurrent Hash Array Mapped Trie . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "Ctrie - A Lock-Free Concurrent Hash Array Mapped Trie ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "Ctrie - A Lock-Free Concurrent Hash Array Mapped Trie ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). Ctrie - A Lock-Free Concurrent Hash Array Mapped Trie . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- Lock-Free Resizeable Concurrent Tries (Slideshow) . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "Lock-Free Resizeable Concurrent Tries (Slideshow) ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "Lock-Free Resizeable Concurrent Tries (Slideshow) ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). Lock-Free Resizeable Concurrent Tries (Slideshow) . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. The lookup operation can be modified to guarantee wait-freedom. == Advantages of Ctries == Ct . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "- Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. The lookup operation can be modified to guarantee wait-freedom. == Advantages of Ctries == Ct ." - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "- Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. The lookup operation can be modified to guarantee wait-freedom. == Advantages of Ctries == Ct ." - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. (2025). - Ctrie operations have been shown to have the atomicity, linearizability and lock-freedom properties. The lookup operation can be modified to guarantee wait-freedom. == Advantages of Ctries == Ct . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- for Scala 2.9.x is available on GitHub. It is a mutable thread-safe implementation which ensures progress and supports lock-free, linearizable, O(1) snapshots. * A data-structure similar to Ctries has . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "for Scala 2.9.x is available on GitHub. It is a mutable thread-safe implementation which ensures progress and supports lock-free, linearizable, O(1) snapshots. * A data-structure similar to Ctries has ." for Scala 2. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "for Scala 2.9.x is available on GitHub. It is a mutable thread-safe implementation which ensures progress and supports lock-free, linearizable, O(1) snapshots. * A data-structure similar to Ctries has ." for Scala 2. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA for Scala 2. (2025). for Scala 2.9.x is available on GitHub. It is a mutable thread-safe implementation which ensures progress and supports lock-free, linearizable, O(1) snapshots. * A data-structure similar to Ctries has . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- scala/src/library/scala/collection/concurrent/TrieMap.scala at 2.13.x . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "scala/src/library/scala/collection/concurrent/TrieMap.scala at 2.13.x ." scala/src/library/scala/collection/concurrent/TrieMap. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "scala/src/library/scala/collection/concurrent/TrieMap.scala at 2.13.x ." scala/src/library/scala/collection/concurrent/TrieMap. 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA scala/src/library/scala/collection/concurrent/TrieMap. (2025). scala/src/library/scala/collection/concurrent/TrieMap.scala at 2.13.x . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
- ctrie: Non-blocking concurrent map . · retrieved 2025-11-11 · rev 1321686798
Cite this reference
MLA "ctrie: Non-blocking concurrent map ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798. Accessed 24 November 2026.
Chicago "ctrie: Non-blocking concurrent map ." 2025-11-11. https://en.wikipedia.org/w/index.php?oldid=1321686798.
APA encyclopegia.org. (2025). ctrie: Non-blocking concurrent map . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1321686798
Cite this article
MLA
"Ctrie." encyclopegia.org, 2025, https://encyclopegia.org/wiki/ctrie. Accessed 24 November 2026.
Chicago
"Ctrie." encyclopegia.org. Accessed November 24, 2026. https://encyclopegia.org/wiki/ctrie.
APA
encyclopegia.org. (2025). Ctrie. Retrieved November 24, 2026, from https://encyclopegia.org/wiki/ctrie
Accessed November 24, 2026 · CC BY-SA 4.0 · citation page · JSON