stop specializing on argument types of `display` (#28616)
there is no real advantage in specializing on the argument types
for display since it goes through a quite complicated machinery
of trying to find applicable displays.
Before:
julia> let
@time precompile(Tuple{typeof(Base.Multimedia.display), Int32})
@time precompile(Tuple{typeof(Base.Multimedia.display), Vector{Int}})
@time precompile(Tuple{typeof(Base.Multimedia.display), Float64})
@time precompile(Tuple{typeof(Base.Multimedia.display), Symbol})
end
0.034542 seconds (37.08 k allocations: 1.916 MiB)
0.042272 seconds (92.57 k allocations: 4.810 MiB)
0.039003 seconds (90.20 k allocations: 4.758 MiB)
0.030826 seconds (61.08 k allocations: 3.066 MiB)
After:
julia> let
@time precompile(Tuple{typeof(Base.Multimedia.display), Int32})
@time precompile(Tuple{typeof(Base.Multimedia.display), Vector{Int}})
@time precompile(Tuple{typeof(Base.Multimedia.display), Float64})
@time precompile(Tuple{typeof(Base.Multimedia.display), Symbol})
end
0.000041 seconds (12 allocations: 640 bytes)
0.000029 seconds (10 allocations: 544 bytes)
0.000024 seconds (9 allocations: 496 bytes)
0.000021 seconds (9 allocations: 496 bytes)