Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "AcceleratedKernels"
uuid = "6a4ca0a5-0e36-4168-a932-d9be78d558f1"
authors = ["Andrei-Leonard Nicusan <[email protected]> and contributors"]
version = "0.3.0"
version = "0.3.1"

[deps]
ArgCheck = "dce04be8-c92d-5529-be00-80e4d2c0e197"
Expand Down
8 changes: 4 additions & 4 deletions src/accumulate/accumulate.jl
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ For compatibility with the `Base.accumulate!` function, we provide the two-array
we do not need the constraint of `dst` and `src` being different; to minimise memory use, we
recommend using the single-array interface (the first one above).

## CPU
## CPU
The CPU implementation is currently single-threaded; we are waiting on a multithreaded
implementation in OhMyThreads.jl ([issue](https://github.com/JuliaFolds2/OhMyThreads.jl/issues/129)).

## GPU
## GPU
For the 1D case (`dims=nothing`), the `alg` can be one of the following:
- `DecoupledLookback()`: the default algorithm, using opportunistic lookback to reuse earlier
blocks' results; requires device-level memory consistency guarantees, which Apple Metal does not
Expand Down Expand Up @@ -241,7 +241,7 @@ function accumulate(
temp::Union{Nothing, AbstractArray}=nothing,
temp_flags::Union{Nothing, AbstractArray}=nothing,
)
dst_type = promote_type(eltype(v), typeof(init))
dst_type = Base.promote_op(op, eltype(v), typeof(init))
vcopy = similar(v, dst_type)
copyto!(vcopy, v)
accumulate!(
Expand All @@ -252,7 +252,7 @@ function accumulate(
inclusive=inclusive,

alg=alg,

block_size=block_size,
temp=temp,
temp_flags=temp_flags,
Expand Down
Loading