-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Invalidations.yml #59
Conversation
This is based on https://github.com/julia-actions/julia-invalidations. Adding such checks came up in https://discourse.julialang.org/t/potential-performance-regressions-in-julia-1-8-for-special-un-precompiled-type-dispatches-and-how-to-fix-them/86359. I suggest to add this check here since this package is widely used as a dependency. See also SciML/MuladdMacro.jl#26 and SciML/MuladdMacro.jl#29
Does this mean that the method definitions in SortingAlgorithms.jl cause no invalidations while DataStructures.jl causes 512 invalidations? |
Is it also possible to get a report of invalidations on the default branch after merging? |
That's definitely weird - I tested it in a dummy repo before and it worked as expected, see https://github.com/ranocha/InvalidationsTest.jl/actions/runs/2971488885/jobs/4758759868#step:10:5
Right now, this CI setup does not support that. It could certainly be modified, though. There is also some work going on to improve this kind of CI, see https://discourse.julialang.org/t/potential-performance-regressions-in-julia-1-8-for-special-un-precompiled-type-dispatches-and-how-to-fix-them/86359/22 |
With Julia 1.8.2, I get julia> import Pkg; Pkg.activate(temp=true); Pkg.add("SortingAlgorithms")
julia> using SnoopCompileCore; invalidations = @snoopr(using SortingAlgorithms); using SnoopCompile
julia> length(uinvalidated(invalidations))
500
julia> trees = invalidation_trees(invalidations)
8-element Vector{SnoopCompile.MethodInvalidations}:
inserting insert!(m::DataStructures.SortedMultiDict{K, D, Ord}, k_, d_) where {K, D, Ord<:Base.Order.Ordering} in DataStructures at ~/.julia/packages/DataStructures/59MD0/src/sorted_multi_dict.jl:167 invalidated:
...
inserting (::Base.var"#sort!##kw")(::Any, ::typeof(sort!), d::OrderedCollections.OrderedDict) in OrderedCollections at ~/.julia/packages/OrderedCollections/PRayh/src/dict_sorting.jl:4 invalidated:
...
inserting merge!(d::AbstractDict, other::DataStructures.PriorityQueue) in DataStructures at ~/.julia/packages/DataStructures/59MD0/src/priorityqueue.jl:360 invalidated:
...
inserting iterate(v::Union{Base.KeySet{<:Any, <:DataStructures.SwissDict}, Base.ValueIterator{<:DataStructures.SwissDict}}) in DataStructures at ~/.julia/packages/DataStructures/59MD0/src/swiss_dict.jl:646 invalidated:
...
inserting convert(::Type{Array}, cb::DataStructures.CircularBuffer{T}) where T in DataStructures at ~/.julia/packages/DataStructures/59MD0/src/circular_buffer.jl:166 invalidated:
...
inserting fpsort!(v::AbstractVector, ::SortingAlgorithms.RadixSortAlg, o::Base.Order.Ordering) in SortingAlgorithms at ~/.julia/packages/SortingAlgorithms/PEcBU/src/SortingAlgorithms.jl:125 invalidated:
...
inserting convert(::Type{OrderedCollections.OrderedDict{K, V}}, d::OrderedCollections.OrderedDict{K, V}) where {K, V} in OrderedCollections at ~/.julia/packages/OrderedCollections/PRayh/src/ordered_dict.jl:110 invalidated:
...
inserting iterate(v::Union{Base.KeySet{<:Any, <:DataStructures.SwissDict}, Base.ValueIterator{<:DataStructures.SwissDict}}, state) in DataStructures at ~/.julia/packages/DataStructures/59MD0/src/swiss_dict.jl:646 invalidated:
... Note the line |
This is based on https://github.com/julia-actions/julia-invalidations. Adding such checks came up in https://discourse.julialang.org/t/potential-performance-regressions-in-julia-1-8-for-special-un-precompiled-type-dispatches-and-how-to-fix-them/86359. I suggest to add this check here since this package is widely used as a dependency.
See also SciML/MuladdMacro.jl#26 and SciML/MuladdMacro.jl#29