Skip to content

Commit 6626b0e

Browse files
Merge pull request #33 from JuliaSIMD/vsum
Quick workaround for `vsum` issue
2 parents fcf6c94 + a39728c commit 6626b0e

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "VectorizedStatistics"
22
uuid = "3b853605-1c98-4422-8364-4bd93ee0529e"
33
authors = ["C. Brenhin Keller", "Chris Elrod"]
4-
version = "0.5.7"
4+
version = "0.5.8"
55

66
[deps]
77
LoopVectorization = "bdcacae8-1622-11e9-2a5c-532679323890"

src/VectorizedStatistics.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
module VectorizedStatistics
22

33
using LoopVectorization, Static
4+
import LoopVectorization.vsum # Will add more specific method for ::StridedArray
45

56
const IntOrStaticInt = Union{Integer, StaticInt}
67
_dim(::Type{StaticInt{N}}) where {N} = N::Int

src/vsum.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ julia> vsum(A, dims=2)
2424
7
2525
```
2626
"""
27-
vsum(A; dim=:, dims=:, multithreaded=False()) = _vsum(A, dim, dims, multithreaded)
27+
vsum(A::StridedArray; dim=:, dims=:, multithreaded=False()) = _vsum(A, dim, dims, multithreaded)
2828
_vsum(A, ::Colon, ::Colon, multithreaded) = _vsum(A, :, multithreaded)
2929
_vsum(A, ::Colon, region, multithreaded) = _vsum(A, region, multithreaded)
3030
_vsum(A, region, ::Colon, multithreaded) = reducedims(_vsum(A, region, multithreaded), region)

0 commit comments

Comments
 (0)