forked from JuliaLang/julia
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Specialize
copyto!
for triangular matrices (JuliaLang#52730)
This provides a performance boost in copying a triangular matrix to a `StridedMatrix`, which is a common operation (e.g. in broadcasting or in `Matrix(::UpperTriangular)`). The main improvement is improved cache locality for strided triangular matrices by fusing the loops. On master ```julia julia> U = UpperTriangular(rand(4000,4000)); julia> @Btime Matrix($U); 64.649 ms (3 allocations: 122.07 MiB) ``` This PR ```julia julia> @Btime Matrix($U); 48.332 ms (3 allocations: 122.07 MiB) ```
- Loading branch information
Showing
2 changed files
with
62 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters