Skip to content

Commit

Permalink
adress review
Browse files Browse the repository at this point in the history
  • Loading branch information
oscardssmith committed Jun 10, 2024
1 parent 0559383 commit 95cab81
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions base/genericmemory.jl
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ GenericMemory
"""
Memory{T} == GenericMemory{:not_atomic, T, Core.CPU}
One-dimensional, fixed-size, dense array with elements of type `T`.
Fixed-size [`DenseVector{T}`](@ref DenseVector).
!!! compat "Julia 1.11"
This type requires Julia 1.11 or later.
Expand All @@ -37,9 +37,12 @@ Memory
"""
AtomicMemory{T} == GenericMemory{:atomic, T, Core.CPU}
!!! warning
Fixed-size [`DenseVector{T}`](@ref DenseVector).
Each element is independently atomic when accessed, and cannot be set non-atomically.
Access to its any of its elements is performed atomically (with `:monotonic` ordering).
Setting any of the elements must be accomplished using the `@atomic` macro and explicitly specifying ordering.
!!! warning
Each element is independently atomic when accessed, and cannot be set non-atomically.
Currently the `@atomic` macro and higher level interface have not been completed,
but the building blocks for a future implementation are the internal intrinsics
`Core.memoryrefget`, `Core.memoryrefset!`, `Core.memoryref_isassigned`, `Core.memoryrefswap!`,
Expand Down

0 comments on commit 95cab81

Please sign in to comment.