An Image/Link below is provided (as is) to download presentation
Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.Content is provided to you AS IS for your information and personal use only.Download presentation by click this link.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.During download, if you can't get a presentation, the file might be deleted by the publisher.
Hash Array Mapped Tries (HAMT) • advantages: • low space consumption and shrinking • no contiguous memory region required • fast – logarithmic complexity, but with a low constant factor • used as efficient immutable maps • no global resize phase – real time applications, potentially more scalable concurrent operations?
Concurrent Trie (Ctrie) • goals: • thread-safe concurrent trie • maintain the advantages of HAMT • rely solely on CAS instructions • ensure lock-freedom and linearizability • lookup – probably same as for HAMT
CAS instruction CAS(address, expected_value, new_value) Atomically replaces the value at the address with the new_value if it is equal to the expected_value. Returns true if successful, false otherwise. May fail spuriously.
Lock-freedom If multiple threads execute an operation, at least one of them will complete the operation within a finite number of steps.
Lock-freedom If multiple threads execute an operation, at least one of them will complete the operation within a finite number of steps. do { a = READ(addr) b = a + 1 } while (!CAS(addr, a, b))
Lock-freedom If multiple threads execute an operation, at least one of them will complete the operation within a finite number of steps. def counter() do { a = READ(addr) b = a + 1 } while (!CAS(addr, a, b))