Skip to content

Commit

Permalink
TODO comments
Browse files Browse the repository at this point in the history
  • Loading branch information
durban committed May 13, 2024
1 parent e3b8e88 commit 9a7790e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions core/shared/src/main/scala/dev/tauri/choam/refs/Ref.scala
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ object Ref extends RefInstances0 {

// TODO: How to avoid allocating RefArrayRef objects?
// TODO: Create getAndUpdate(idx: Int, f: A => A) methods.
// TODO: (Implement them with something like `OffsetMemoryLocation`.)
// TODO: But: what to do with out-of-bounds indices?
// TODO: (Refined? But can we avoid boxing?)
// TODO: Would implementing Traverse help? Probably not.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,9 @@ private[mcas] final class Emcas extends GlobalContext { global =>
* since it checked.
* So versions by themselves don't save us from ABA-problems,
* because we can't CAS them together with the values.
* We could, if we had a double-word-CAS (or would implement
* something like RDCSS or GCAS). But instead we use marks...
* TODO: We could, if we had a double-word-CAS (or would implement
* TODO: something like RDCSS or GCAS).
* But instead we use marks...
*
* To guarantee that in-use descriptors are never replaced,
* every thread (the original and any helpers) must always
Expand Down Expand Up @@ -226,6 +227,10 @@ private[mcas] final class Emcas extends GlobalContext { global =>
* status itself; this is a successful op
*/

// TODO: Most accesses here (and elsewhere) are volatile;
// TODO: figure out if we can use acq/rel, and still remain
// TODO: correct.

// Listing 2 in the paper:

/**
Expand Down

0 comments on commit 9a7790e

Please sign in to comment.