JuliaSIMD / JuliaSIMD/LoopVectorization.jl

Support for 'triangular' loops

Open
#77 9 comments 6 reactions 0 assignees View on GitHub
Dominant language
Julia
Stars
789
Forks
73
PR merge metrics
No merged PRs in 30d

Description

Suppose I have a function
```julia
function pairwise(a)
ret = Matrix{eltype(a)}(undef, length(a), length(a))
for i in 1:(length(a)-1)
for j in (i+1):length(a)
ret[i, j] = a[i] * a[j]
end
end
UpperTriangular(ret)
end
```
Is there a way to represent this loop over the 'upper triangular indices' of `ret` with LoopVectorization.jl?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.