You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I profiled the package loading of FillArrays.jl, and realized that it is massively dominated by SparseArrays.jl:
julia>@time_importsusing FillArrays
┌ 7.6 ms SparseArrays.CHOLMOD.__init__() 81.29% compilation time
507.8 ms SparseArrays 6.95% compilation time
1.1 ms Statistics
41.5 ms FillArrays
That will improve on v1.10.beta1 to roughly half of it, but still. Given that many many packages depend directly or indirectly on FillArrays.jl, it would help the ecosystem a lot if package load time of FillArrays.jl could be reduced. Is it possible to make SparseArrays.jl a weak dependency? I see
convert(::Type{AbstractSparseMatrix}, Z::Eye{T}) where {T} =SparseMatrixCSC{T}(I, size(Z)...)
convert(::Type{AbstractSparseMatrix{Tv}}, Z::Eye{T}) where {T,Tv} =SparseMatrixCSC{Tv}(I, size(Z)...)
convert(::Type{AbstractSparseArray}, Z::Eye{T}) where T =SparseMatrixCSC{T}(I, size(Z)...)
convert(::Type{AbstractSparseArray{Tv}}, Z::Eye{T}) where {T,Tv} =SparseMatrixCSC{Tv}(I, size(Z)...)
convert(::Type{AbstractSparseArray{Tv,Ti}}, Z::Eye{T}) where {T,Tv,Ti} =
convert(SparseMatrixCSC{Tv,Ti}, Z)
convert(::Type{AbstractSparseArray{Tv,Ti,2}}, Z::Eye{T}) where {T,Tv,Ti} =
convert(SparseMatrixCSC{Tv,Ti}, Z)
functionSparseMatrixCSC{Tv}(R::RectOrDiagonalFill) where {Tv}
SparseMatrixCSC{Tv,eltype(axes(R,1))}(R)
end
functionSparseMatrixCSC{Tv,Ti}(R::RectOrDiagonalFill) where {Tv,Ti}
Base.require_one_based_indexing(R)
v =parent(R)
J =getindex_value(v)*I
SparseMatrixCSC{Tv,Ti}(J, size(R))
end
which cry for a weak dependency, but then there is also some kron stuff going on. The same applies to Statistics.jl, which currently depends strongly on SparseArrays.jl, so to make a difference, both packages would need to be handled as a package extension.
The text was updated successfully, but these errors were encountered:
I profiled the package loading of
FillArrays.jl
, and realized that it is massively dominated bySparseArrays.jl
:That will improve on v1.10.beta1 to roughly half of it, but still. Given that many many packages depend directly or indirectly on
FillArrays.jl
, it would help the ecosystem a lot if package load time ofFillArrays.jl
could be reduced. Is it possible to makeSparseArrays.jl
a weak dependency? I seeFillArrays.jl/src/FillArrays.jl
Lines 545 to 590 in 1efbdbb
kron
stuff going on. The same applies toStatistics.jl
, which currently depends strongly onSparseArrays.jl
, so to make a difference, both packages would need to be handled as a package extension.The text was updated successfully, but these errors were encountered: